Input:
  protected void render(final PatchScript script, final PatchSetDetail detail) {
    final ArrayList<Object> lines = new ArrayList<Object>();
    final SafeHtmlBuilder nc = new SafeHtmlBuilder();
    allocateTableHeader(script, nc);
    lines.add(null);
    if (!isDisplayBinary) {
      if (script.getFileModeA() != FileMode.FILE
          || script.getFileModeB() != FileMode.FILE) {
        openLine(nc);
        appendModeLine(nc, script.getFileModeA());
        appendModeLine(nc, script.getFileModeB());
        closeLine(nc);
        lines.add(null);
      }
      if (hasDifferences(script)) {
        int lastA = 0;
        int lastB = 0;
        final boolean ignoreWS = script.isIgnoreWhitespace();
        a = getSparseHtmlFileA(script);
        b = getSparseHtmlFileB(script);
        final boolean intraline =
            script.getDiffPrefs().isIntralineDifference()
                && script.hasIntralineDifference();
        for (final EditList.Hunk hunk : script.getHunks()) {
          if (!hunk.isStartOfFile()) {
            appendSkipLine(nc, hunk.getCurB() - lastB);
            lines.add(new SkippedLine(lastA, lastB, hunk.getCurB() - lastB));
          }
          while (hunk.next()) {
            if (hunk.isContextLine()) {
              openLine(nc);
              final SafeHtml ctx = a.getSafeHtmlLine(hunk.getCurA());
              appendLineNumber(nc, hunk.getCurA(), false);
              appendLineText(nc, CONTEXT, ctx, false, false);
              if (ignoreWS && b.contains(hunk.getCurB())) {
                appendLineText(nc, CONTEXT, b, hunk.getCurB(), false);
              } else {
                appendLineText(nc, CONTEXT, ctx, false, false);
              }
              appendLineNumber(nc, hunk.getCurB(), true);
              closeLine(nc);
              hunk.incBoth();
              lines.add(new PatchLine(CONTEXT, hunk.getCurA(), hunk.getCurB()));
            } else if (hunk.isModifiedLine()) {
              final boolean del = hunk.isDeletedA();
              final boolean ins = hunk.isInsertedB();
              final boolean full =
                  intraline && hunk.getCurEdit().getType() != Edit.Type.REPLACE;
              openLine(nc);
              if (del) {
                appendLineNumber(nc, hunk.getCurA(), false);
                appendLineText(nc, DELETE, a, hunk.getCurA(), full);
                hunk.incA();
              } else if (hunk.getCurEdit().getType() == Edit.Type.REPLACE) {
                appendLineNumber(nc, false);
                appendLineNone(nc, DELETE);
              } else {
                appendLineNumber(nc, false);
                appendLineNone(nc, CONTEXT);
              }
              if (ins) {
                appendLineText(nc, INSERT, b, hunk.getCurB(), full);
                appendLineNumber(nc, hunk.getCurB(), true);
                hunk.incB();
              } else if (hunk.getCurEdit().getType() == Edit.Type.REPLACE) {
                appendLineNone(nc, INSERT);
                appendLineNumber(nc, true);
              } else {
                appendLineNone(nc, CONTEXT);
                appendLineNumber(nc, true);
              }
              closeLine(nc);
              if (del && ins) {
                lines.add(new PatchLine(REPLACE, hunk.getCurA(), hunk.getCurB()));
              } else if (del) {
                lines.add(new PatchLine(DELETE, hunk.getCurA(), -1));
              } else if (ins) {
                lines.add(new PatchLine(INSERT, -1, hunk.getCurB()));
              }
            }
          }
          lastA = hunk.getCurA();
          lastB = hunk.getCurB();
        }
        if (lastB != b.size()) {
          appendSkipLine(nc, b.size() - lastB);
          lines.add(new SkippedLine(lastA, lastB, b.size() - lastB));
        }
      }
    }else{
      for (final String line : script.getPatchHeader()) {
        appendFileHeader(nc, line);
      }
    }
    if (!hasDifferences(script)) {
      appendNoDifferences(nc);
    }
    resetHtml(nc);
    populateTableHeader(script, detail);
    if (hasDifferences(script)) {
      initScript(script);
      if (!isDisplayBinary) {
        for (int row = 0; row < lines.size(); row++) {
          setRowItem(row, lines.get(row));
          if (lines.get(row) instanceof SkippedLine) {
            createSkipLine(row, (SkippedLine) lines.get(row));
          }
        }
      }
    }
  }

Output:
  protected void render(final PatchScript script, final PatchSetDetail detail) {
    final ArrayList<Object> lines = new ArrayList<Object>();
    final SafeHtmlBuilder nc = new SafeHtmlBuilder();
    allocateTableHeader(script, nc);
    lines.add(null);
    if (!isDisplayBinary) {
      if (script.getFileModeA() != FileMode.FILE
          || script.getFileModeB() != FileMode.FILE) {
        openLine(nc);
        appendModeLine(nc, script.getFileModeA());
        appendModeLine(nc, script.getFileModeB());
        closeLine(nc);
        lines.add(null);
      }
      if (hasDifferences(script)) {
        int lastA = 0;
        int lastB = 0;
        final boolean ignoreWS = script.isIgnoreWhitespace();
        a = getSparseHtmlFileA(script);
        b = getSparseHtmlFileB(script);
        final boolean intraline =
            script.getDiffPrefs().isIntralineDifference()
                && script.hasIntralineDifference();
        for (final EditList.Hunk hunk : script.getHunks()) {
          if (!hunk.isStartOfFile()) {
            appendSkipLine(nc, hunk.getCurB() - lastB);
            lines.add(new SkippedLine(lastA, lastB, hunk.getCurB() - lastB));
          }
          while (hunk.next()) {
            if (hunk.isContextLine()) {
              openLine(nc);
              final SafeHtml ctx = a.getSafeHtmlLine(hunk.getCurA());
              appendLineNumber(nc, hunk.getCurA(), false);
              appendLineText(nc, CONTEXT, ctx, false, false);
              if (ignoreWS && b.contains(hunk.getCurB())) {
                appendLineText(nc, CONTEXT, b, hunk.getCurB(), false);
              } else {
                appendLineText(nc, CONTEXT, ctx, false, false);
              }
              appendLineNumber(nc, hunk.getCurB(), true);
              closeLine(nc);
              hunk.incBoth();
              lines.add(new PatchLine(CONTEXT, hunk.getCurA(), hunk.getCurB()));
            } else if (hunk.isModifiedLine()) {
              final boolean del = hunk.isDeletedA();
              final boolean ins = hunk.isInsertedB();
              final boolean full =
                  intraline && hunk.getCurEdit().getType() != Edit.Type.REPLACE;
              openLine(nc);
              if (del) {
                appendLineNumber(nc, hunk.getCurA(), false);
                appendLineText(nc, DELETE, a, hunk.getCurA(), full);
                hunk.incA();
              } else if (hunk.getCurEdit().getType() == Edit.Type.REPLACE) {
                appendLineNumber(nc, false);
                appendLineNone(nc, DELETE);
              } else {
                appendLineNumber(nc, false);
                appendLineNone(nc, CONTEXT);
              }
              if (ins) {
                appendLineText(nc, INSERT, b, hunk.getCurB(), full);
                appendLineNumber(nc, hunk.getCurB(), true);
                hunk.incB();
              } else if (hunk.getCurEdit().getType() == Edit.Type.REPLACE) {
                appendLineNone(nc, INSERT);
                appendLineNumber(nc, true);
              } else {
                appendLineNone(nc, CONTEXT);
                appendLineNumber(nc, true);
              }
              closeLine(nc);
              if (del && ins) {
                lines.add(new PatchLine(REPLACE, hunk.getCurA(), hunk.getCurB()));
              } else if (del) {
                lines.add(new PatchLine(DELETE, hunk.getCurA(), -1));
              } else if (ins) {
                lines.add(new PatchLine(INSERT, -1, hunk.getCurB()));
              }
            }
          }
          lastA = hunk.getCurA();
          lastB = hunk.getCurB();
        }
        if (lastB != b.size()) {
          appendSkipLine(nc, b.size() - lastB);
          lines.add(new SkippedLine(lastA, lastB, b.size() - lastB));
        }
      }
    } else {
      for (final String line : script.getPatchHeader()) {
        appendFileHeader(nc, line);
      }
    }
    if (!hasDifferences(script)) {
      appendNoDifferences(nc);
    }
    resetHtml(nc);
    populateTableHeader(script, detail);
    if (hasDifferences(script)) {
      initScript(script);
      if (!isDisplayBinary) {
        for (int row = 0; row < lines.size(); row++) {
          setRowItem(row, lines.get(row));
          if (lines.get(row) instanceof SkippedLine) {
            createSkipLine(row, (SkippedLine) lines.get(row));
          }
        }
      }
    }
  }


Input:
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.random_choise);
		Intent intent = getIntent();
		mUri = intent.getData();
		tv = (TextView)findViewById(R.id.random_result);
		buttonstart = (Button) findViewById(R.id.button_start);
		buttonstart.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				mCursor = managedQuery(mUri, FoodColumn.PROJECTION, null, null, null);
				mCursor.moveToFirst();
				max = mCursor.getCount();
				long id = numx.nextInt(max)+1;
				Uri uri = ContentUris.withAppendedId(getIntent().getData(), id);
				mCursor = managedQuery(uri, FoodColumn.PROJECTION, null, null, null);
				Log.e(TAG + ":onCreate", mCursor.toString() + "  " + id + max);
				mCursor.moveToFirst();
				random_result = mCursor.getString(FoodColumn.NAME_COLUMN);
				tv.setText(random_result);
			}
		});
	}

Output:
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.random_choise);
		Intent intent = getIntent();
		mUri = intent.getData();
		tv = (TextView)findViewById(R.id.random_result);
		buttonstart = (Button) findViewById(R.id.button_start);
		buttonstart.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				mCursor = managedQuery(mUri, FoodColumn.PROJECTION, null, null, null);
				mCursor.moveToFirst();
				max = mCursor.getCount();
				long id = numx.nextInt(max);
				while(id>0){
					mCursor.moveToNext();
					id=id-1;
				}
				random_result = mCursor.getString(FoodColumn.NAME_COLUMN);
				tv.setText(random_result);
			}
		});
	}


Input:
  protected boolean moveRobot(State st, Command cmd) {
    int nextCol;
    int nextRow;
    switch (cmd) {
    case Left:
      nextCol = st.robotCol - 1;
      nextRow = st.robotRow;
      break;
    case Right:
      nextCol = st.robotCol + 1;
      nextRow = st.robotRow;
      break;
    case Up:
      nextCol = st.robotCol;
      nextRow = st.robotRow + 1;
      break;
    case Down:
      nextCol = st.robotCol;
      nextRow = st.robotRow - 1;
      break;
    case Wait:
      return true;
    case Abort:
      st.ending = Ending.Abort;
      return true;
    case Shave:
      st.shaveBeard(st.robotCol, st.robotRow);
      return true;
    default:
      throw new IllegalArgumentException("Unknown command " + cmd);
    }
    Cell next = st.board.get(nextCol, nextRow);
    switch (next) {
    case Lambda:
      ++st.collectedLambdas;
      st.removeLambda(nextCol, nextRow);
    case Empty:
    case Earth:
      moveRobot(st, nextCol, nextRow);
      return true;
    case Lift:
      if (st.lambdaPositions.isEmpty() && st.board.bitsets[Cell.HoRock.ordinal()].isEmpty() && st.board.bitsets[Cell.FallingHoRock.ordinal()].isEmpty()) {
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      return false;
    case Razor:
     ++st.board.razors;
     moveRobot(st, nextCol, nextRow);
     return true;
    case Rock:
    case FallingRock:
      if (cmd == Command.Left && st.board.get(nextCol - 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol - 1, nextRow, Cell.FallingRock);
        fallingPosition(st, nextCol - 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      if (cmd == Command.Right && st.board.get(nextCol + 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol + 1, nextRow, Cell.FallingRock);
        fallingPosition(st, nextCol + 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
    case HoRock:
    case FallingHoRock:
      if (cmd == Command.Left && st.board.get(nextCol - 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol - 1, nextRow, Cell.FallingHoRock);
        fallingPosition(st, nextCol - 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      if (cmd == Command.Right && st.board.get(nextCol + 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol + 1, nextRow, Cell.FallingHoRock);
        fallingPosition(st, nextCol + 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
    case Target:
      return false;
    case Trampoline:
      int trampolinePos = st.board.position(nextCol, nextRow);
      String trampoline = st.board.trampolinePos.get(trampolinePos);
      st.board.set(nextCol, nextRow, Cell.Empty);
      String target = st.board.trampolineTargets.get(trampoline);
      int jumpPos = st.board.targetPos.get(target);
      st.board.set(jumpPos, Cell.Empty);
      int jumpCol = st.board.col(jumpPos);
      int jumpRow = st.board.row(jumpPos);
      moveRobot(st, jumpCol, jumpRow);
      removeTrampolines(target, st);
      return true;
    default:
      return false;
    }
  }

Output:
  protected boolean moveRobot(State st, Command cmd) {
    int nextCol;
    int nextRow;
    switch (cmd) {
    case Left:
      nextCol = st.robotCol - 1;
      nextRow = st.robotRow;
      break;
    case Right:
      nextCol = st.robotCol + 1;
      nextRow = st.robotRow;
      break;
    case Up:
      nextCol = st.robotCol;
      nextRow = st.robotRow + 1;
      break;
    case Down:
      nextCol = st.robotCol;
      nextRow = st.robotRow - 1;
      break;
    case Wait:
      return true;
    case Abort:
      st.ending = Ending.Abort;
      return true;
    case Shave:
      return st.shaveBeard(st.robotCol, st.robotRow);
    default:
      throw new IllegalArgumentException("Unknown command " + cmd);
    }
    Cell next = st.board.get(nextCol, nextRow);
    switch (next) {
    case Lambda:
      ++st.collectedLambdas;
      st.removeLambda(nextCol, nextRow);
    case Empty:
    case Earth:
      moveRobot(st, nextCol, nextRow);
      return true;
    case Lift:
      if (st.lambdaPositions.isEmpty() && st.board.bitsets[Cell.HoRock.ordinal()].isEmpty() && st.board.bitsets[Cell.FallingHoRock.ordinal()].isEmpty()) {
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      return false;
    case Razor:
     ++st.board.razors;
     moveRobot(st, nextCol, nextRow);
     return true;
    case Rock:
    case FallingRock:
      if (cmd == Command.Left && st.board.get(nextCol - 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol - 1, nextRow, Cell.FallingRock);
        fallingPosition(st, nextCol - 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      if (cmd == Command.Right && st.board.get(nextCol + 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol + 1, nextRow, Cell.FallingRock);
        fallingPosition(st, nextCol + 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
    case HoRock:
    case FallingHoRock:
      if (cmd == Command.Left && st.board.get(nextCol - 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol - 1, nextRow, Cell.FallingHoRock);
        fallingPosition(st, nextCol - 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
      if (cmd == Command.Right && st.board.get(nextCol + 1, nextRow) == Cell.Empty) {
        st.board.set(nextCol + 1, nextRow, Cell.FallingHoRock);
        fallingPosition(st, nextCol + 1, nextRow);
        moveRobot(st, nextCol, nextRow);
        return true;
      }
    case Target:
      return false;
    case Trampoline:
      int trampolinePos = st.board.position(nextCol, nextRow);
      String trampoline = st.board.trampolinePos.get(trampolinePos);
      st.board.set(nextCol, nextRow, Cell.Empty);
      String target = st.board.trampolineTargets.get(trampoline);
      int jumpPos = st.board.targetPos.get(target);
      st.board.set(jumpPos, Cell.Empty);
      int jumpCol = st.board.col(jumpPos);
      int jumpRow = st.board.row(jumpPos);
      moveRobot(st, jumpCol, jumpRow);
      removeTrampolines(target, st);
      return true;
    default:
      return false;
    }
  }


Input:
    private PluginDescriptor getPluginDescriptor(String groupId, String artifactId, String version) {
      String name = groupId + ":" + artifactId + ":" + version;
      PluginDescriptor descriptor = descriptors.get(name);
      if(descriptor!=null) {
        return descriptor;
      }
      MavenPlugin plugin = MavenPlugin.getDefault();
      MavenConsole console = plugin.getConsole();
      try {
        IMaven embedder = MavenPlugin.lookup(IMaven.class);
        IndexManager indexManager = MavenPlugin.getDefault().getIndexManager();
        List<ArtifactRepository> repositories = indexManager.getArtifactRepositories(null, null);
        Artifact artifact = embedder.resolve(groupId, artifactId, version, null, "maven-plugin", repositories, null);
        File file = artifact.getFile();
        if(file == null) {
          String msg = "Can't resolve plugin " + name;
          console.logError(msg);
        } else {
          InputStream is = null;
          ZipFile zf = null;
          try {
            zf = new ZipFile(file);
            ZipEntry entry = zf.getEntry("META-INF/maven/plugin.xml");
            if(entry != null) {
              is = zf.getInputStream(entry);
              PluginDescriptorBuilder builder = new PluginDescriptorBuilder();
              descriptor = builder.build(new InputStreamReader(is));
              descriptors.put(name, descriptor);
              return descriptor;
            }
          } catch(Exception ex) {
            String msg = "Can't read configuration for " + name;
            console.logError(msg);
            MavenLogger.log(msg, ex);
          } finally {
            IOUtil.close(is);
            try {
              zf.close();
            } catch(IOException ex) {
            }
          }
        }
      } catch(CoreException ex) {
        IStatus status = ex.getStatus();
        console.logError(status.getMessage() + "; " + status.getException().getMessage());
        MavenLogger.log(ex);
      }
      return null;
    }

Output:
    private PluginDescriptor getPluginDescriptor(String groupId, String artifactId, String version) {
      String name = groupId + ":" + artifactId + ":" + version;
      PluginDescriptor descriptor = descriptors.get(name);
      if(descriptor!=null) {
        return descriptor;
      }
      MavenPlugin plugin = MavenPlugin.getDefault();
      MavenConsole console = plugin.getConsole();
      try {
        IMaven embedder = MavenPlugin.lookup(IMaven.class);
        IndexManager indexManager = MavenPlugin.getDefault().getIndexManager();
        List<ArtifactRepository> repositories = indexManager.getArtifactRepositories(null, null);
        Artifact artifact = embedder.resolve(groupId, artifactId, version, "maven-plugin", null,  repositories, null);
        File file = artifact.getFile();
        if(file == null) {
          String msg = "Can't resolve plugin " + name;
          console.logError(msg);
        } else {
          InputStream is = null;
          ZipFile zf = null;
          try {
            zf = new ZipFile(file);
            ZipEntry entry = zf.getEntry("META-INF/maven/plugin.xml");
            if(entry != null) {
              is = zf.getInputStream(entry);
              PluginDescriptorBuilder builder = new PluginDescriptorBuilder();
              descriptor = builder.build(new InputStreamReader(is));
              descriptors.put(name, descriptor);
              return descriptor;
            }
          } catch(Exception ex) {
            String msg = "Can't read configuration for " + name;
            console.logError(msg);
            MavenLogger.log(msg, ex);
          } finally {
            IOUtil.close(is);
            try {
              zf.close();
            } catch(IOException ex) {
            }
          }
        }
      } catch(CoreException ex) {
        IStatus status = ex.getStatus();
        console.logError(status.getMessage() + "; " + status.getException().getMessage());
        MavenLogger.log(ex);
      }
      return null;
    }


Input:
    public boolean onCommand(CommandSender sender, Command cmd, String commandLabel, String[] args) {
        if (config.getMainConfig().isSpectatorsChatHidden() && pm.getGamer((Player) sender).isSpectator()) {
            sender.sendMessage(tm.getCommandMeSpectating());
            return true;
        }
        Bukkit.broadcastMessage("* " + ((Player) sender).getDisplayName() + ChatColor.RESET + " " + StringUtils.join(args, " "));
        return true;
    }

Output:
    public boolean onCommand(CommandSender sender, Command cmd, String commandLabel, String[] args) {
        if (config.getMainConfig().isSpectatorsChatHidden() && pm.getGamer((Player) sender).isSpectator()) {
            sender.sendMessage(tm.getCommandMeSpectating());
            return true;
        }
        if (args.length == 0) {
            return false;
        } else {
            Bukkit.broadcastMessage("* " + ((Player) sender).getDisplayName() + ChatColor.RESET + " " + StringUtils.join(args, " "));
            return true;
        }
    }


Input:
		protected SelectEvent select()
		{
			if (getHandlerCount(SelectEvent.getType()) > 0)
			{
				return SelectEvent.fire(this);
			}
			else if (!StringUtils.isEmpty(getHref()))
			{
				if (!StringUtils.isEmpty(getTarget()))
				{
					Window.open(getHref(), getTarget(), null);
				}
				else
				{
					Window.Location.assign(getHref());
				}
			}
			return null;
		}

Output:
		protected SelectEvent select()
		{
			if (getHandlerCount(SelectEvent.getType()) > 0)
			{
				return SelectEvent.fire(this);
			}
			else if (!StringUtils.isEmpty(getHref()))
			{
				if (!StringUtils.isEmpty(getTarget()))
				{
					Window.open(getHref(), getTarget(), "");
				}
				else
				{
					Window.Location.assign(getHref());
				}
			}
			return null;
		}


Input:
	private void runWithSelection(final Object selectedObject) {
		AbstractTask repositoryTask = null;
		if (selectedObject instanceof TaskEditor) {
			TaskEditor editor = (TaskEditor) selectedObject;
			AbstractTask task = editor.getTaskEditorInput().getTask();
			if (task != null) {
				repositoryTask = task;
			}
		} else if (selectedObject instanceof AbstractRepositoryTaskEditor) {
			AbstractRepositoryTaskEditor editor = (AbstractRepositoryTaskEditor) selectedObject;
			repositoryTask = editor.getRepositoryTask();
		}
		if (repositoryTask != null) {
			AbstractRepositoryConnector connector = TasksUiPlugin.getRepositoryManager().getRepositoryConnector(
					repositoryTask.getConnectorKind());
			if (connector != null) {
				TasksUiPlugin.getSynchronizationManager().synchronize(connector, repositoryTask, false,
						new JobChangeAdapter() {
							@Override
							public void done(IJobChangeEvent event) {
								PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
									public void run() {
										if (selectedObject instanceof TaskEditor) {
											TaskEditor editor = (TaskEditor) selectedObject;
											editor.refreshEditorContents();
										} else if (selectedObject instanceof AbstractRepositoryTaskEditor) {
											((AbstractRepositoryTaskEditor) selectedObject).refreshEditor();
										}
									}
								});
							}
						});
			}
		}
	}

Output:
	private void runWithSelection(final Object selectedObject) {
		AbstractTask repositoryTask = null;
		if (selectedObject instanceof TaskEditor) {
			TaskEditor editor = (TaskEditor) selectedObject;
			AbstractTask task = editor.getTaskEditorInput().getTask();
			if (task != null) {
				repositoryTask = task;
			}
		} else if (selectedObject instanceof AbstractRepositoryTaskEditor) {
			AbstractRepositoryTaskEditor editor = (AbstractRepositoryTaskEditor) selectedObject;
			repositoryTask = editor.getRepositoryTask();
		}
		if (repositoryTask != null) {
			AbstractRepositoryConnector connector = TasksUiPlugin.getRepositoryManager().getRepositoryConnector(
					repositoryTask.getConnectorKind());
			if (connector != null) {
				TasksUiPlugin.getSynchronizationManager().synchronize(connector, repositoryTask, true,
						new JobChangeAdapter() {
							@Override
							public void done(IJobChangeEvent event) {
								PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
									public void run() {
										if (selectedObject instanceof TaskEditor) {
											TaskEditor editor = (TaskEditor) selectedObject;
											editor.refreshEditorContents();
										} else if (selectedObject instanceof AbstractRepositoryTaskEditor) {
											((AbstractRepositoryTaskEditor) selectedObject).refreshEditor();
										}
									}
								});
							}
						});
			}
		}
	}


Input:
    public EndResettingEvent(World world, short dragonAmount, String message){
        this.world = world;
        this.dragonAmount = dragonAmount;
    }

Output:
    public EndResettingEvent(World world, short dragonAmount, String message){
        this.world = world;
        this.dragonAmount = dragonAmount;
        this.message = message;
    }


Input:
	public void load(FMLInitializationEvent event)
	{
		addArmorItem(obsidianHelmet, new ItemStack(Block.obsidian), "Obsidian Helmet", 0);
		addArmorItem(obsidianChestplate, new ItemStack(Block.obsidian), "Obsidian Chestplate", 1);
		addArmorItem(obsidianLeggings, new ItemStack(Block.obsidian), "Obsidian Leggings", 2);
		addArmorItem(obsidianBoots, new ItemStack(Block.obsidian), "Obsidian Boots", 3);
		addArmorItem(redstoneHelmet, new ItemStack(Item.redstone), "Redstone Helmet", 0);
		addArmorItem(redstoneChestplate, new ItemStack(Item.redstone), "Redstone Chestplate", 1);
		addArmorItem(redstoneLeggings, new ItemStack(Item.redstone), "Redstone Leggings", 2);
		addArmorItem(redstoneBoots, new ItemStack(Item.redstone), "Redstone Boots", 3);
		addArmorItem(coalHelmet, new ItemStack(Item.coal), "Coal Helmet", 0);
		addArmorItem(coalChestplate, new ItemStack(Item.coal), "Coal Chestplate", 1);
		addArmorItem(coalLeggings, new ItemStack(Item.coal), "Coal Leggings", 2);
		addArmorItem(coalBoots, new ItemStack(Item.coal), "Coal Boots", 3);
		addArmorItem(lapisHelmet, new ItemStack(Block.blockLapis), "Lapis Helmet", 0);
		addArmorItem(lapisChestplate, new ItemStack(Block.blockLapis), "Lapis Chestplate", 1);
		addArmorItem(lapisLeggings, new ItemStack(Block.blockLapis), "Lapis Leggings", 2);
		addArmorItem(lapisBoots, new ItemStack(Block.blockLapis), "Lapis Boots", 3);
		addArmorItem(enderHelmet, new ItemStack(Item.enderPearl), "Ender Helmet", 0);
		addArmorItem(enderChestplate, new ItemStack(Item.enderPearl), "Ender Chestplate", 1);
		addArmorItem(enderLeggings, new ItemStack(Item.enderPearl), "Ender Leggings", 2);
		addArmorItem(enderBoots, new ItemStack(Item.enderPearl), "Ender Boots", 3);
		addArmorItem(spaceHelmet, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Helmet", 0);
		addArmorItem(spaceChestplate, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Chestplate", 1);
		addArmorItem(spaceLeggings, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Leggings", 2);
		addArmorItem(spaceBoots, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Boots", 3);
		addArmorItem(boneHelmet, new ItemStack(Item.bone), "Bone Helmet", 0);
		addArmorItem(boneChestplate, new ItemStack(Item.bone), "Bone Chestplate", 1);
		addArmorItem(boneLeggings, new ItemStack(Item.bone), "Bone Leggings", 2);
		addArmorItem(boneBoots, new ItemStack(Item.bone), "Bone Boots", 3);
		addArmorItem(sugarcaneHelmet, new ItemStack(Item.reed), "Sugarcane Helmet", 0);
		addArmorItem(sugarcaneChestplate, new ItemStack(Item.reed), "Sugarcane Chestplate", 1);
		addArmorItem(sugarcaneLeggings, new ItemStack(Item.reed), "Sugarcane Leggings", 2);
		addArmorItem(sugarcaneBoots, new ItemStack(Item.reed), "Sugarcane Boots", 3);
		addArmorItem(blazerodHelmet, new ItemStack(Item.blazeRod), "Blaze Helmet", 0);
		addArmorItem(blazerodChestplate, new ItemStack(Item.blazeRod), "Blaze Chestplate", 1);
		addArmorItem(blazerodLeggings, new ItemStack(Item.blazeRod), "Blaze Leggings", 2);
		addArmorItem(blazerodBoots, new ItemStack(Item.blazeRod), "Blaze Boots", 3);
		addArmorItem(dirtHelmet, new ItemStack(Block.dirt), "Dirt Helmet", 0);
		addArmorItem(dirtChestplate, new ItemStack(Block.dirt), "Dirt Chestplate", 1);
		addArmorItem(dirtLeggings, new ItemStack(Block.dirt), "Dirt Leggings", 2);
		addArmorItem(dirtBoots, new ItemStack(Block.dirt), "Dirt Boots", 3);
		addArmorItem(glassHelmet, new ItemStack(Block.glass), "Glass Helmet", 0);
		addArmorItem(glassChestplate, new ItemStack(Block.glass), "Glass Chestplate", 1);
		addArmorItem(glassLeggings, new ItemStack(Block.glass), "Glass Leggings", 2);
		addArmorItem(glassBoots, new ItemStack(Block.glass), "Glass Boots", 3);
		addArmorItem(sandstoneHelmet, new ItemStack(Block.sandStone), "Sandstone Helmet", 0);
		addArmorItem(sandstoneChestplate, new ItemStack(Block.sandStone), "Sandstone Chestplate", 1);
		addArmorItem(sandstoneLeggings, new ItemStack(Block.sandStone), "Sandstone Leggings", 2);
		addArmorItem(sandstoneBoots, new ItemStack(Block.sandStone), "Sandstone Boots", 3);
		addArmorItem(brickHelmet, new ItemStack(Item.brick), "Brick Helmet", 0);
		addArmorItem(brickChestplate, new ItemStack(Item.brick), "Brick Chestplate", 1);
		addArmorItem(brickLeggings, new ItemStack(Item.brick), "Brick Leggings", 2);
		addArmorItem(brickBoots, new ItemStack(Item.brick), "Brick Boots", 3);
		addArmorItem(endstoneHelmet, new ItemStack(Block.whiteStone), "Endstone Helmet", 0);
		addArmorItem(endstoneChestplate, new ItemStack(Block.whiteStone), "Endstone Chestplate", 1);
		addArmorItem(endstoneLeggings, new ItemStack(Block.whiteStone), "Endstone Leggings", 2);
		addArmorItem(endstoneBoots, new ItemStack(Block.whiteStone), "Endstone Boots", 3);
		addName(hallowedHelmet, "God's Helmet");
		addName(hallowedChestplate, "God's Chestplate");
		addName(hallowedLeggings, "God's Leggings");
		addName(hallowedBoots, "God's Boots");
		ModLoader.addRecipe(new ItemStack(hallowedHelmet, 1), new Object[]{
			"XXX",
			"XxX",
			Character.valueOf('x'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedChestplate, 1), new Object[]{
			"XxX",
			"XXX",
			"XXX",
			Character.valueOf('x'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedLeggings, 1), new Object[]{
			"XXX",
			"XxX",
			"XxX",
			Character.valueOf('x'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedHelmet, 1), new Object[]{
			"x x",
			"XxX",
			"XxX",
			Character.valueOf('x'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		addName(goddawnHelmet, "Luzifer's Helmet");
		addName(goddawnChestplate, "Luzifer's Chestplate");
		addName(goddawnLeggings, "Luzifer's Leggings");
		addName(goddawnBoots, "Luzifer's Boots");
		ModLoader.addRecipe(new ItemStack(goddawnHelmet, 1), new Object[]{
			"XXX",
			"XxX",
			Character.valueOf('x'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnChestplate, 1), new Object[]{
			"XxX",
			"XXX",
			"XXX",
			Character.valueOf('x'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnLeggings, 1), new Object[]{
			"XXX",
			"XxX",
			"XxX",
			Character.valueOf('x'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnHelmet, 1), new Object[]{
			"x x",
			"XxX",
			"XxX",
			Character.valueOf('x'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		CSItems.addItemWithRecipe(invisibilityHelmet, 0, "Invisibility Helmet", 1, new Object[] { "XxX", "X X", 'X', Item.ingotIron, 'x', Item.diamond });

Output:
	public void load(FMLInitializationEvent event)
	{
		addArmorItem(obsidianHelmet, new ItemStack(Block.obsidian), "Obsidian Helmet", 0);
		addArmorItem(obsidianChestplate, new ItemStack(Block.obsidian), "Obsidian Chestplate", 1);
		addArmorItem(obsidianLeggings, new ItemStack(Block.obsidian), "Obsidian Leggings", 2);
		addArmorItem(obsidianBoots, new ItemStack(Block.obsidian), "Obsidian Boots", 3);
		addArmorItem(redstoneHelmet, new ItemStack(Item.redstone), "Redstone Helmet", 0);
		addArmorItem(redstoneChestplate, new ItemStack(Item.redstone), "Redstone Chestplate", 1);
		addArmorItem(redstoneLeggings, new ItemStack(Item.redstone), "Redstone Leggings", 2);
		addArmorItem(redstoneBoots, new ItemStack(Item.redstone), "Redstone Boots", 3);
		addArmorItem(coalHelmet, new ItemStack(Item.coal), "Coal Helmet", 0);
		addArmorItem(coalChestplate, new ItemStack(Item.coal), "Coal Chestplate", 1);
		addArmorItem(coalLeggings, new ItemStack(Item.coal), "Coal Leggings", 2);
		addArmorItem(coalBoots, new ItemStack(Item.coal), "Coal Boots", 3);
		addArmorItem(lapisHelmet, new ItemStack(Block.blockLapis), "Lapis Helmet", 0);
		addArmorItem(lapisChestplate, new ItemStack(Block.blockLapis), "Lapis Chestplate", 1);
		addArmorItem(lapisLeggings, new ItemStack(Block.blockLapis), "Lapis Leggings", 2);
		addArmorItem(lapisBoots, new ItemStack(Block.blockLapis), "Lapis Boots", 3);
		addArmorItem(enderHelmet, new ItemStack(Item.enderPearl), "Ender Helmet", 0);
		addArmorItem(enderChestplate, new ItemStack(Item.enderPearl), "Ender Chestplate", 1);
		addArmorItem(enderLeggings, new ItemStack(Item.enderPearl), "Ender Leggings", 2);
		addArmorItem(enderBoots, new ItemStack(Item.enderPearl), "Ender Boots", 3);
		addArmorItem(spaceHelmet, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Helmet", 0);
		addArmorItem(spaceChestplate, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Chestplate", 1);
		addArmorItem(spaceLeggings, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Leggings", 2);
		addArmorItem(spaceBoots, new ItemStack(MoreToolsMod_Tools.spaceIngot), "Space Boots", 3);
		addArmorItem(boneHelmet, new ItemStack(Item.bone), "Bone Helmet", 0);
		addArmorItem(boneChestplate, new ItemStack(Item.bone), "Bone Chestplate", 1);
		addArmorItem(boneLeggings, new ItemStack(Item.bone), "Bone Leggings", 2);
		addArmorItem(boneBoots, new ItemStack(Item.bone), "Bone Boots", 3);
		addArmorItem(sugarcaneHelmet, new ItemStack(Item.reed), "Sugarcane Helmet", 0);
		addArmorItem(sugarcaneChestplate, new ItemStack(Item.reed), "Sugarcane Chestplate", 1);
		addArmorItem(sugarcaneLeggings, new ItemStack(Item.reed), "Sugarcane Leggings", 2);
		addArmorItem(sugarcaneBoots, new ItemStack(Item.reed), "Sugarcane Boots", 3);
		addArmorItem(blazerodHelmet, new ItemStack(Item.blazeRod), "Blaze Helmet", 0);
		addArmorItem(blazerodChestplate, new ItemStack(Item.blazeRod), "Blaze Chestplate", 1);
		addArmorItem(blazerodLeggings, new ItemStack(Item.blazeRod), "Blaze Leggings", 2);
		addArmorItem(blazerodBoots, new ItemStack(Item.blazeRod), "Blaze Boots", 3);
		addArmorItem(dirtHelmet, new ItemStack(Block.dirt), "Dirt Helmet", 0);
		addArmorItem(dirtChestplate, new ItemStack(Block.dirt), "Dirt Chestplate", 1);
		addArmorItem(dirtLeggings, new ItemStack(Block.dirt), "Dirt Leggings", 2);
		addArmorItem(dirtBoots, new ItemStack(Block.dirt), "Dirt Boots", 3);
		addArmorItem(glassHelmet, new ItemStack(Block.glass), "Glass Helmet", 0);
		addArmorItem(glassChestplate, new ItemStack(Block.glass), "Glass Chestplate", 1);
		addArmorItem(glassLeggings, new ItemStack(Block.glass), "Glass Leggings", 2);
		addArmorItem(glassBoots, new ItemStack(Block.glass), "Glass Boots", 3);
		addArmorItem(sandstoneHelmet, new ItemStack(Block.sandStone), "Sandstone Helmet", 0);
		addArmorItem(sandstoneChestplate, new ItemStack(Block.sandStone), "Sandstone Chestplate", 1);
		addArmorItem(sandstoneLeggings, new ItemStack(Block.sandStone), "Sandstone Leggings", 2);
		addArmorItem(sandstoneBoots, new ItemStack(Block.sandStone), "Sandstone Boots", 3);
		addArmorItem(brickHelmet, new ItemStack(Item.brick), "Brick Helmet", 0);
		addArmorItem(brickChestplate, new ItemStack(Item.brick), "Brick Chestplate", 1);
		addArmorItem(brickLeggings, new ItemStack(Item.brick), "Brick Leggings", 2);
		addArmorItem(brickBoots, new ItemStack(Item.brick), "Brick Boots", 3);
		addArmorItem(endstoneHelmet, new ItemStack(Block.whiteStone), "Endstone Helmet", 0);
		addArmorItem(endstoneChestplate, new ItemStack(Block.whiteStone), "Endstone Chestplate", 1);
		addArmorItem(endstoneLeggings, new ItemStack(Block.whiteStone), "Endstone Leggings", 2);
		addArmorItem(endstoneBoots, new ItemStack(Block.whiteStone), "Endstone Boots", 3);
		addName(hallowedHelmet, "God's Helmet");
		addName(hallowedChestplate, "God's Chestplate");
		addName(hallowedLeggings, "God's Leggings");
		addName(hallowedBoots, "God's Boots");
		ModLoader.addRecipe(new ItemStack(hallowedHelmet, 1), new Object[]{
			"XXX",
			"XxX",
			Character.valueOf('X'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedChestplate, 1), new Object[]{
			"XxX",
			"XXX",
			"XXX",
			Character.valueOf('X'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedLeggings, 1), new Object[]{
			"XXX",
			"XxX",
			"XxX",
			Character.valueOf('X'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(hallowedHelmet, 1), new Object[]{
			"x x",
			"XxX",
			"XxX",
			Character.valueOf('X'), Block.blockGold,
			Character.valueOf('x'), Item.redstone
		});
		addName(goddawnHelmet, "Luzifer's Helmet");
		addName(goddawnChestplate, "Luzifer's Chestplate");
		addName(goddawnLeggings, "Luzifer's Leggings");
		addName(goddawnBoots, "Luzifer's Boots");
		ModLoader.addRecipe(new ItemStack(goddawnHelmet, 1), new Object[]{
			"XXX",
			"XxX",
			Character.valueOf('X'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnChestplate, 1), new Object[]{
			"XxX",
			"XXX",
			"XXX",
			Character.valueOf('X'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnLeggings, 1), new Object[]{
			"XXX",
			"XxX",
			"XxX",
			Character.valueOf('X'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		ModLoader.addRecipe(new ItemStack(goddawnHelmet, 1), new Object[]{
			"x x",
			"XxX",
			"XxX",
			Character.valueOf('x'), Block.netherrack,
			Character.valueOf('x'), Item.redstone
		});
		CSItems.addItemWithRecipe(invisibilityHelmet, 0, "Invisibility Helmet", 1, new Object[] { "XxX", "X X", 'X', Item.ingotIron, 'x', Item.diamond });


Input:
	public void obscureRect(Rect rect, Canvas canvas) {
		try
		{
		  Bitmap mask = loadBitmap(_context,"party.png");
		  canvas.drawBitmap(mask, null, rect, _painter);
		}
		catch (IOException e)
		{
			Log.e("anon",e.toString(),e);
		}
	}

Output:
	public void obscureRect(Rect rect, Canvas canvas) {
		try
		{
		  Bitmap mask = loadBitmap(_context,"anon.png");
		  canvas.drawBitmap(mask, null, rect, _painter);
		}
		catch (IOException e)
		{
			Log.e("anon",e.toString(),e);
		}
	}


Input:
	public static Boolean run(CommandSender sender, String alias, String[] args) {
		if(Vault.permsEnabled() != true) {
			 LogHelper.logSevere(_("permissionsNotFound", ""));
			 LogHelper.showWarning("permissionsNotFound", sender);
		}
		if(args.length==0) {
			Commands.showCommandHelpAndUsage(sender, "cex_setrank", alias);
		}
		Player player = Bukkit.getServer().getPlayerExact(args[0]);
		String group = args[1];
		Vault.perms.playerAddGroup(player, group);
		LogHelper.showInfo("[" + player + "setrankToSender#####[" + group, sender);
		LogHelper.showInfo("setrankToPlayer#####[" + group, player);
		return true;
	}

Output:
	public static Boolean run(CommandSender sender, String alias, String[] args) {
		if(Vault.permsEnabled() != true) {
			 LogHelper.logSevere(_("permissionsNotFound", ""));
			 LogHelper.showWarning("permissionsNotFound", sender);
		}
		if(args.length != 2) {
			Commands.showCommandHelpAndUsage(sender, "cex_setrank", alias);
			return true;
		}
		Player player = Bukkit.getServer().getPlayerExact(args[0]);
		String group = args[1];
		Vault.perms.playerAddGroup(player, group);
		LogHelper.showInfo("[" + player + "setrankToSender#####[" + group, sender);
		LogHelper.showInfo("setrankToPlayer#####[" + group, player);
		return true;
	}


Input:
	public List<NameNumberXml> lookupMemberById(@QueryParam("q") String q) {
		List<NameNumberXml> results = em
				.createQuery(
						"select new com.laurinka.skga.server.rest.model.NameNumberXml(m.name2, m.nr) from SkgaNumber m "
								+ "where m.name2 is not null "
								+ "and m.name2 like :name" + " order by m.nr desc",
						NameNumberXml.class)
				.setParameter("custName", "%" + q + "%").setMaxResults(10)
				.getResultList();
		return results;
	}

Output:
	public List<NameNumberXml> lookupMemberById(@QueryParam("q") String q) {
		List<NameNumberXml> results = em
				.createQuery(
						"select new com.laurinka.skga.server.rest.model.NameNumberXml(m.name2, m.nr) from SkgaNumber m "
								+ "where m.name2 is not null "
								+ "and m.name2 like :name" + " order by m.nr desc",
						NameNumberXml.class)
				.setParameter("name", "%" + q + "%").setMaxResults(10)
				.getResultList();
		return results;
	}


Input:
    public void load(FMLInitializationEvent event)
    {
		NetworkRegistry.instance().registerGuiHandler(this, new GuiHandler());
		gpu = new BlockGPU(542, Material.iron);
		GameRegistry.registerBlock(gpu, "CCLGPU");
		GameRegistry.registerTileEntity(TileEntityGPU.class, "GPU");
		GameRegistry.addRecipe(new ItemStack(gpu,1),new Object[]{
			"III",
			"RGR",
			"GGG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold});
		monitor = new BlockMonitor(543, Material.iron);
		GameRegistry.registerBlock(monitor, "CCLMonitor");
		GameRegistry.registerTileEntity(TileEntityMonitor.class, "CCLMonitorTE");
		GameRegistry.addRecipe(new ItemStack(monitor,2),new Object[]{
			"III",
			"RLR",
			"GGG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold,'L',Block.thinGlass});
		monitorBig = new BlockBigMonitor(545, Material.iron);
		GameRegistry.registerBlock(monitorBig, "CCLBigMonitor");
		GameRegistry.registerTileEntity(TileEntityBigMonitor.class, "CCLBigMonitorTE");
		GameRegistry.addRecipe(new ItemStack(monitorBig,16),new Object[]{
			"LLL",
			"LGL",
			"LLL",'G',gpu,'L',Block.thinGlass});
		ram = new ItemRAM(4097-256);
		GameRegistry.registerItem(ram, "CCLRAM");
		LanguageRegistry.addName(ram, "RAM");
		GameRegistry.addRecipe(new ItemStack(ram,8),new Object[]{
			"III",
			"R R",
			"GGG",'I',Item.ingotIron,'R',Block.blockRedstone,'G',Item.ingotGold,'L',Block.thinGlass});
		tablet = new ItemTablet(4098);
		GameRegistry.registerItem(tablet, "CCLTab");
		LanguageRegistry.addName(tablet, "Tablet");
		GameRegistry.addRecipe(new ItemStack(tablet,2),new Object[]{
			"GIG",
			"RMR",
			"GIG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold,'M',monitorBig});
		proxy.registerRenderInfo();
		MinecraftForge.EVENT_BUS.register(new Events());
    }

Output:
    public void load(FMLInitializationEvent event)
    {
		NetworkRegistry.instance().registerGuiHandler(this, new GuiHandler());
		gpu = new BlockGPU(542, Material.iron);
		GameRegistry.registerBlock(gpu, "CCLGPU");
		GameRegistry.registerTileEntity(TileEntityGPU.class, "GPU");
		GameRegistry.addRecipe(new ItemStack(gpu,1),new Object[]{
			"III",
			"RGR",
			"GGG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold});
		monitor = new BlockMonitor(543, Material.iron);
		GameRegistry.registerBlock(monitor, "CCLMonitor");
		GameRegistry.registerTileEntity(TileEntityMonitor.class, "CCLMonitorTE");
		GameRegistry.addRecipe(new ItemStack(monitor,2),new Object[]{
			"III",
			"RLR",
			"GGG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold,'L',Block.thinGlass});
		monitorBig = new BlockBigMonitor(545, Material.iron);
		GameRegistry.registerBlock(monitorBig, "CCLBigMonitor");
		GameRegistry.registerTileEntity(TileEntityBigMonitor.class, "CCLBigMonitorTE");
		GameRegistry.addRecipe(new ItemStack(monitorBig,16),new Object[]{
			"LLL",
			"LGL",
			"LLL",'G',monitor,'L',Block.thinGlass});
		ram = new ItemRAM(4097-256);
		GameRegistry.registerItem(ram, "CCLRAM");
		LanguageRegistry.addName(ram, "RAM");
		GameRegistry.addRecipe(new ItemStack(ram,8),new Object[]{
			"III",
			"R R",
			"GGG",'I',Item.ingotIron,'R',Block.blockRedstone,'G',Item.ingotGold,'L',Block.thinGlass});
		tablet = new ItemTablet(4098);
		GameRegistry.registerItem(tablet, "CCLTab");
		LanguageRegistry.addName(tablet, "Tablet");
		GameRegistry.addRecipe(new ItemStack(tablet,2),new Object[]{
			"GIG",
			"RMR",
			"GIG",'I',Item.ingotIron,'R',Item.redstone,'G',Item.ingotGold,'M',monitorBig});
		proxy.registerRenderInfo();
		MinecraftForge.EVENT_BUS.register(new Events());
    }


Input:
    protected void renderTokens(Graphics2D g, List<Token> tokenList) {
    	Grid grid = zone.getGrid();
    	Dimension screenSize = getSize();
        int scaledGridWidth = (int)(grid.getCellWidth()*getScale());
        int scaledGridHeight = (int)(grid.getCellHeight()*getScale());
        Rectangle clipBounds = g.getClipBounds();
        float scale = zoneScale.getScale();
        double gridSize = getScaledGridSize();
        for (Token token : tokenList) {
        	if (!zone.isTokenVisible(token) && !AppUtil.playerOwns(token)) {
        		continue;
        	}
            int width = (int)Math.ceil(TokenSize.getWidth(token, zone.getGrid()) * scale);
            int height = (int)Math.ceil(TokenSize.getHeight(token, zone.getGrid()) * scale);
            if (!token.isStamp()) {
            	width --;
            	height --;
            }
            ScreenPoint tokenScreenLocation = ScreenPoint.fromZonePoint(this, token.getX(), token.getY());
            int x = tokenScreenLocation.x + 1 + (int)(grid.getCellOffset().width*scale);
            int y = tokenScreenLocation.y + 1 + (int)(grid.getCellOffset().height*scale);
            if (width < scaledGridWidth && token.isSnapToGrid()) {
                x += (scaledGridWidth - width)/2;
            }
            if (height < scaledGridHeight && token.isSnapToGrid()) {
                y += (scaledGridHeight - height)/2;
            }
            Rectangle tokenBounds = new Rectangle(x, y, width, height);
            if (x+width < 0 || x > screenSize.width || y+height < 0 || y > screenSize.height) {
            	continue;
            }
            if (!token.isStamp() && !token.isBackground()) {
	            for (TokenLocation location : getTokenLocations(Zone.Layer.TOKEN)) {
	            	Rectangle r1 = location.bounds;
	            	if (tokenBounds.intersects(r1)) {
	            		Rectangle oldRect = null;
	            		for (Rectangle r2 : coveredTokenSet) {
	            			if (tokenBounds.contains(r2)) {
	            				oldRect = r2;
	            				break;
	            			}
	            		}
	            		if (oldRect != null) {
	            			coveredTokenSet.remove(oldRect);
	            		}
	            		coveredTokenSet.add(tokenBounds);
	            	}
	            }
            }
            List<TokenLocation> locationList = null;
            if (!token.isStamp() && !token.isBackground()) {
            	locationList = getTokenLocations(Zone.Layer.TOKEN);
            } else {
            	if (token.isStamp()) {
            		locationList = getTokenLocations(Zone.Layer.STAMP);
            	}
            	if (token.isBackground()) {
            		locationList = getTokenLocations(Zone.Layer.BACKGROUND);
            	}
            }
            if (locationList != null) {
            	locationList.add(new TokenLocation(tokenBounds, token));
            }
			BufferedImage image = null;
            Asset asset = AssetManager.getAsset(token.getAssetID());
            if (asset == null) {
                MapTool.serverCommand().getAsset(token.getAssetID());
                image = ImageManager.UNKNOWN_IMAGE;
            } else {
				image = ImageManager.getImage(AssetManager.getAsset(token.getAssetID()), this);
            }
            if (!tokenBounds.intersects(clipBounds)) {
                continue;
            }
			if (isTokenMoving(token)) {
				BufferedImage replacementImage = replacementImageMap.get(token);
				if (replacementImage == null) {
					replacementImage = ImageUtil.rgbToGrayscale(image);
					replacementImageMap.put(token, replacementImage);
				}
				image = replacementImage;
			}
			if (showPathList.contains(token) && token.getLastPath() != null) {
				renderPath(g, token.getLastPath(), (int)(width/gridSize), (int)(height/gridSize));
			}
			if (token.hasFacing() && (token.getTokenType() == Token.Type.TOP_DOWN || token.isStamp() || token.isBackground())) {
				AffineTransform at = new AffineTransform();
				at.translate(x, y);
				at.rotate(Math.toRadians(-token.getFacing() - 90), width/2, height/2);
				if (token.isSnapToScale()) {
					at.scale((double)TokenSize.getWidth(token, zone.getGrid()) / token.getWidth(), (double)TokenSize.getHeight(token, zone.getGrid()) / token.getHeight());
				} else {
					at.scale((double) token.getWidth() / image.getWidth(), (double) token.getHeight() / image.getHeight());
				}
				at.scale(getScale(), getScale());
	            g.drawImage(image, at, this);
			} else {
	            g.drawImage(image, x, y, width, height, this);
			}
			if (token.hasFacing()) {
				Token.Type tokenType = token.getTokenType();
				switch(tokenType) {
				case CIRCLE:
					int size = TokenSize.getWidth(token, zone.getGrid())/2;
					Shape arrow = getCircleFacingArrow(token.getFacing(), size);
					int cx = x + width/2;
					int cy = y + height/2;
					g.translate(cx, cy);
					g.setColor(Color.yellow);
					g.fill(arrow);
					g.setColor(Color.darkGray);
					g.draw(arrow);
					g.translate(-cx, -cy);
					break;
				case SQUARE:
					size = TokenSize.getWidth(token, zone.getGrid())/2;
					int facing = token.getFacing();
					arrow = getSquareFacingArrow(facing, size);
					cx = x + width/2;
					cy = y + height/2;
					int xp = width/2;
					int yp = height/2;
					if (facing >= 45 && facing <= 135 || facing <= -45 && facing >= -135) {
						xp = (int)(yp / Math.tan(Math.toRadians(facing)));
						if (facing < 0 ) {
							xp = -xp;
							yp = -yp;
						}
					} else {
						yp = (int)(xp * Math.tan(Math.toRadians(facing)));
						if (facing > 135 || facing < -135) {
							xp = -xp;
							yp = -yp;
						}
					}
					cx += xp;
					cy -= yp;
					g.translate(cx, cy);
					g.setColor(Color.yellow);
					g.fill(arrow);
					g.setColor(Color.darkGray);
					g.draw(arrow);
					g.translate(-cx, -cy);
					break;
				}
			}
            if (!token.getStatePropertyNames().isEmpty()) {
              Shape clip = g.getClip();
              g.translate(x, y);
              Rectangle bounds = new Rectangle(0, 0, width, height);
              Rectangle overlayClip = g.getClipBounds().intersection(bounds);
              g.setClip(overlayClip);
              for (String state : token.getStatePropertyNames()) {
                Object stateValue = token.getState(state);
                if (stateValue instanceof Boolean && ((Boolean)stateValue).booleanValue()) {
                  TokenOverlay overlay =  TokenStates.getOverlay(state);
                  if (overlay != null) overlay.paintOverlay(g, token, bounds);
                } else if (stateValue instanceof TokenOverlay) {
                  ((TokenOverlay)stateValue).paintOverlay(g, token, bounds);
                }
              }
              g.translate(-x, -y);
              g.setClip(clip);
            }
        }
        for (TokenLocation location : getTokenLocations(getActiveLayer())) {
        	Rectangle bounds = location.bounds;
            if (!bounds.intersects(clipBounds)) {
                continue;
            }
        	Token token = location.token;
        	boolean isSelected = selectedTokenSet.contains(token.getId());
        	if (isSelected) {
        		ImageBorder selectedBorder = token.isStamp() || token.isBackground() ? AppStyle.selectedStampBorder : AppStyle.selectedBorder;
    			if (token.hasFacing() && (token.getTokenType() == Token.Type.TOP_DOWN || token.isStamp() || token.isBackground())) {
    				AffineTransform oldTransform = g.getTransform();
    				g.translate(bounds.x, bounds.y);
    				g.rotate(Math.toRadians(-token.getFacing() - 90), bounds.width/2, bounds.height/2);
    				selectedBorder.paintAround(g, 0, 0, bounds.width, bounds.height);
    				g.setTransform(oldTransform);
    			} else {
    				selectedBorder.paintAround(g, bounds);
    			}
        	}
        	if (AppState.isShowTokenNames() || isSelected || token == tokenUnderMouse) {
        		String name = token.getName();
        		if (MapTool.getPlayer().isGM() && token.getGMName() != null && token.getGMName().length() > 0) {
        			name += " (" + token.getGMName() + ")";
        		}
                GraphicsUtil.drawBoxedString(g, name, bounds.x + bounds.width/2, bounds.y + bounds.height + 10);
            }
        }
        for (Rectangle rect : coveredTokenSet) {
        	BufferedImage stackImage = AppStyle.stackImage;
        	g.drawImage(stackImage, rect.x + rect.width - stackImage.getWidth() + 2, rect.y - 2, null);
        }
    }

Output:
    protected void renderTokens(Graphics2D g, List<Token> tokenList) {
    	Grid grid = zone.getGrid();
    	Dimension screenSize = getSize();
        int scaledGridWidth = (int)(grid.getCellWidth()*getScale());
        int scaledGridHeight = (int)(grid.getCellHeight()*getScale());
        Rectangle clipBounds = g.getClipBounds();
        float scale = zoneScale.getScale();
        double gridSize = getScaledGridSize();
        for (Token token : tokenList) {
        	if (!zone.isTokenVisible(token) && !MapTool.getPlayer().isGM()) {
        		continue;
        	}
            int width = (int)Math.ceil(TokenSize.getWidth(token, zone.getGrid()) * scale);
            int height = (int)Math.ceil(TokenSize.getHeight(token, zone.getGrid()) * scale);
            if (!token.isStamp()) {
            	width --;
            	height --;
            }
            ScreenPoint tokenScreenLocation = ScreenPoint.fromZonePoint(this, token.getX(), token.getY());
            int x = tokenScreenLocation.x + 1 + (int)(grid.getCellOffset().width*scale);
            int y = tokenScreenLocation.y + 1 + (int)(grid.getCellOffset().height*scale);
            if (width < scaledGridWidth && token.isSnapToGrid()) {
                x += (scaledGridWidth - width)/2;
            }
            if (height < scaledGridHeight && token.isSnapToGrid()) {
                y += (scaledGridHeight - height)/2;
            }
            Rectangle tokenBounds = new Rectangle(x, y, width, height);
            if (x+width < 0 || x > screenSize.width || y+height < 0 || y > screenSize.height) {
            	continue;
            }
            if (!token.isStamp() && !token.isBackground()) {
	            for (TokenLocation location : getTokenLocations(Zone.Layer.TOKEN)) {
	            	Rectangle r1 = location.bounds;
	            	if (tokenBounds.intersects(r1)) {
	            		Rectangle oldRect = null;
	            		for (Rectangle r2 : coveredTokenSet) {
	            			if (tokenBounds.contains(r2)) {
	            				oldRect = r2;
	            				break;
	            			}
	            		}
	            		if (oldRect != null) {
	            			coveredTokenSet.remove(oldRect);
	            		}
	            		coveredTokenSet.add(tokenBounds);
	            	}
	            }
            }
            List<TokenLocation> locationList = null;
            if (!token.isStamp() && !token.isBackground()) {
            	locationList = getTokenLocations(Zone.Layer.TOKEN);
            } else {
            	if (token.isStamp()) {
            		locationList = getTokenLocations(Zone.Layer.STAMP);
            	}
            	if (token.isBackground()) {
            		locationList = getTokenLocations(Zone.Layer.BACKGROUND);
            	}
            }
            if (locationList != null) {
            	locationList.add(new TokenLocation(tokenBounds, token));
            }
			BufferedImage image = null;
            Asset asset = AssetManager.getAsset(token.getAssetID());
            if (asset == null) {
                MapTool.serverCommand().getAsset(token.getAssetID());
                image = ImageManager.UNKNOWN_IMAGE;
            } else {
				image = ImageManager.getImage(AssetManager.getAsset(token.getAssetID()), this);
            }
            if (!tokenBounds.intersects(clipBounds)) {
                continue;
            }
			if (isTokenMoving(token)) {
				BufferedImage replacementImage = replacementImageMap.get(token);
				if (replacementImage == null) {
					replacementImage = ImageUtil.rgbToGrayscale(image);
					replacementImageMap.put(token, replacementImage);
				}
				image = replacementImage;
			}
			if (showPathList.contains(token) && token.getLastPath() != null) {
				renderPath(g, token.getLastPath(), (int)(width/gridSize), (int)(height/gridSize));
			}
			if (token.hasFacing() && (token.getTokenType() == Token.Type.TOP_DOWN || token.isStamp() || token.isBackground())) {
				AffineTransform at = new AffineTransform();
				at.translate(x, y);
				at.rotate(Math.toRadians(-token.getFacing() - 90), width/2, height/2);
				if (token.isSnapToScale()) {
					at.scale((double)TokenSize.getWidth(token, zone.getGrid()) / token.getWidth(), (double)TokenSize.getHeight(token, zone.getGrid()) / token.getHeight());
				} else {
					at.scale((double) token.getWidth() / image.getWidth(), (double) token.getHeight() / image.getHeight());
				}
				at.scale(getScale(), getScale());
	            g.drawImage(image, at, this);
			} else {
	            g.drawImage(image, x, y, width, height, this);
			}
			if (token.hasFacing()) {
				Token.Type tokenType = token.getTokenType();
				switch(tokenType) {
				case CIRCLE:
					int size = TokenSize.getWidth(token, zone.getGrid())/2;
					Shape arrow = getCircleFacingArrow(token.getFacing(), size);
					int cx = x + width/2;
					int cy = y + height/2;
					g.translate(cx, cy);
					g.setColor(Color.yellow);
					g.fill(arrow);
					g.setColor(Color.darkGray);
					g.draw(arrow);
					g.translate(-cx, -cy);
					break;
				case SQUARE:
					size = TokenSize.getWidth(token, zone.getGrid())/2;
					int facing = token.getFacing();
					arrow = getSquareFacingArrow(facing, size);
					cx = x + width/2;
					cy = y + height/2;
					int xp = width/2;
					int yp = height/2;
					if (facing >= 45 && facing <= 135 || facing <= -45 && facing >= -135) {
						xp = (int)(yp / Math.tan(Math.toRadians(facing)));
						if (facing < 0 ) {
							xp = -xp;
							yp = -yp;
						}
					} else {
						yp = (int)(xp * Math.tan(Math.toRadians(facing)));
						if (facing > 135 || facing < -135) {
							xp = -xp;
							yp = -yp;
						}
					}
					cx += xp;
					cy -= yp;
					g.translate(cx, cy);
					g.setColor(Color.yellow);
					g.fill(arrow);
					g.setColor(Color.darkGray);
					g.draw(arrow);
					g.translate(-cx, -cy);
					break;
				}
			}
            if (!token.getStatePropertyNames().isEmpty()) {
              Shape clip = g.getClip();
              g.translate(x, y);
              Rectangle bounds = new Rectangle(0, 0, width, height);
              Rectangle overlayClip = g.getClipBounds().intersection(bounds);
              g.setClip(overlayClip);
              for (String state : token.getStatePropertyNames()) {
                Object stateValue = token.getState(state);
                if (stateValue instanceof Boolean && ((Boolean)stateValue).booleanValue()) {
                  TokenOverlay overlay =  TokenStates.getOverlay(state);
                  if (overlay != null) overlay.paintOverlay(g, token, bounds);
                } else if (stateValue instanceof TokenOverlay) {
                  ((TokenOverlay)stateValue).paintOverlay(g, token, bounds);
                }
              }
              g.translate(-x, -y);
              g.setClip(clip);
            }
        }
        for (TokenLocation location : getTokenLocations(getActiveLayer())) {
        	Rectangle bounds = location.bounds;
            if (!bounds.intersects(clipBounds)) {
                continue;
            }
        	Token token = location.token;
        	boolean isSelected = selectedTokenSet.contains(token.getId());
        	if (isSelected) {
        		ImageBorder selectedBorder = token.isStamp() || token.isBackground() ? AppStyle.selectedStampBorder : AppStyle.selectedBorder;
    			if (token.hasFacing() && (token.getTokenType() == Token.Type.TOP_DOWN || token.isStamp() || token.isBackground())) {
    				AffineTransform oldTransform = g.getTransform();
    				g.translate(bounds.x, bounds.y);
    				g.rotate(Math.toRadians(-token.getFacing() - 90), bounds.width/2, bounds.height/2);
    				selectedBorder.paintAround(g, 0, 0, bounds.width, bounds.height);
    				g.setTransform(oldTransform);
    			} else {
    				selectedBorder.paintAround(g, bounds);
    			}
        	}
        	if (AppState.isShowTokenNames() || isSelected || token == tokenUnderMouse) {
        		String name = token.getName();
        		if (MapTool.getPlayer().isGM() && token.getGMName() != null && token.getGMName().length() > 0) {
        			name += " (" + token.getGMName() + ")";
        		}
                GraphicsUtil.drawBoxedString(g, name, bounds.x + bounds.width/2, bounds.y + bounds.height + 10);
            }
        }
        for (Rectangle rect : coveredTokenSet) {
        	BufferedImage stackImage = AppStyle.stackImage;
        	g.drawImage(stackImage, rect.x + rect.width - stackImage.getWidth() + 2, rect.y - 2, null);
        }
    }


Input:
    private int loadPersistenceUnits(final ModuleLoader moduleLoader, final DeploymentUnit deploymentUnit, final Set<String> moduleDependencies, final PersistenceUnitMetadataHolder holder) throws DeploymentUnitProcessingException {
        int defaultProviderCount = 0;
        if (holder != null) {
            for (PersistenceUnitMetadata pu : holder.getPersistenceUnits()) {
                String providerModule = pu.getProperties().getProperty(Configuration.PROVIDER_MODULE);
                String adapterModule = pu.getProperties().getProperty(Configuration.ADAPTER_MODULE);
                String adapterClass = pu.getProperties().getProperty(Configuration.ADAPTER_CLASS);
                if(providerModule != null) {
                    if (providerModule.equals(Configuration.PROVIDER_MODULE_HIBERNATE3_BUNDLED)) {
                        adapterClass = HIBERNATE3_PROVIDER_ADAPTOR;
                        pu.getProperties().put(Configuration.ADAPTER_CLASS, adapterClass);
                        pu.getProperties().put(Configuration.PROVIDER_MODULE, Configuration.PROVIDER_MODULE_APPLICATION_SUPPLIED);
                        pu.getProperties().remove(Configuration.ADAPTER_MODULE);
                        addHibernate3AdaptorToDeployment(moduleLoader, deploymentUnit);
                    } else if (providerModule.equals(Configuration.PROVIDER_MODULE_HIBERNATE3)) {
                        if (adapterModule == null) {
                            adapterModule = Configuration.ADAPTER_MODULE_HIBERNATE3;
                            pu.getProperties().put(Configuration.ADAPTER_MODULE, adapterModule);
                        }
                    }
                }
                if (adapterModule != null) {
                    ROOT_LOGGER.debugf("%s is configured to use adapter module '%s'", pu.getPersistenceUnitName(), adapterModule);
                    moduleDependencies.add(adapterModule);
                }
                deploymentUnit.putAttachment(JpaAttachments.ADAPTOR_CLASS_NAME, adapterClass);
                String provider = pu.getProperties().getProperty(Configuration.PROVIDER_MODULE);
                if (provider != null) {
                    if (provider.equals(Configuration.PROVIDER_MODULE_APPLICATION_SUPPLIED)) {
                        ROOT_LOGGER.debugf("%s is configured to use application supplied persistence provider", pu.getPersistenceUnitName());
                    } else {
                        moduleDependencies.add(provider);
                    }
                } else if (pu.getPersistenceProviderClassName() == null || pu.getPersistenceProviderClassName().equals(Configuration.ADAPTER_MODULE_DEFAULT)){
                    defaultProviderCount++;
                }
            }
        }
        return defaultProviderCount;
    }

Output:
    private int loadPersistenceUnits(final ModuleLoader moduleLoader, final DeploymentUnit deploymentUnit, final Set<String> moduleDependencies, final PersistenceUnitMetadataHolder holder) throws DeploymentUnitProcessingException {
        int defaultProviderCount = 0;
        if (holder != null) {
            for (PersistenceUnitMetadata pu : holder.getPersistenceUnits()) {
                String providerModule = pu.getProperties().getProperty(Configuration.PROVIDER_MODULE);
                String adapterModule = pu.getProperties().getProperty(Configuration.ADAPTER_MODULE);
                String adapterClass = pu.getProperties().getProperty(Configuration.ADAPTER_CLASS);
                if(providerModule != null) {
                    if (providerModule.equals(Configuration.PROVIDER_MODULE_HIBERNATE3_BUNDLED)) {
                        adapterClass = HIBERNATE3_PROVIDER_ADAPTOR;
                        pu.getProperties().put(Configuration.ADAPTER_CLASS, adapterClass);
                        pu.getProperties().put(Configuration.PROVIDER_MODULE, Configuration.PROVIDER_MODULE_APPLICATION_SUPPLIED);
                        pu.getProperties().remove(Configuration.ADAPTER_MODULE);
                        addHibernate3AdaptorToDeployment(moduleLoader, deploymentUnit);
                    } else if (providerModule.equals(Configuration.PROVIDER_MODULE_HIBERNATE3)) {
                        if (adapterModule == null) {
                            adapterModule = Configuration.ADAPTER_MODULE_HIBERNATE3;
                            pu.getProperties().put(Configuration.ADAPTER_MODULE, adapterModule);
                        }
                    }
                }
                if (adapterModule != null) {
                    ROOT_LOGGER.debugf("%s is configured to use adapter module '%s'", pu.getPersistenceUnitName(), adapterModule);
                    moduleDependencies.add(adapterModule);
                }
                deploymentUnit.putAttachment(JpaAttachments.ADAPTOR_CLASS_NAME, adapterClass);
                String provider = pu.getProperties().getProperty(Configuration.PROVIDER_MODULE);
                if (provider != null) {
                    if (provider.equals(Configuration.PROVIDER_MODULE_APPLICATION_SUPPLIED)) {
                        ROOT_LOGGER.debugf("%s is configured to use application supplied persistence provider", pu.getPersistenceUnitName());
                    } else {
                        moduleDependencies.add(provider);
                    }
                } else if (Configuration.PROVIDER_CLASS_DEFAULT.equals(pu.getPersistenceProviderClassName())){
                    defaultProviderCount++;
                }
            }
        }
        return defaultProviderCount;
    }


Input:
    private void processLine(String s) throws IOException {
        if (s==null) return ;
        if (s.length()==0) return;
        String[] parts=s.split(" ");
        parts=removeEmpty(parts);
        if ("#".equals(parts[0])) return;
        if ("v".equals(parts[0])){
            addVertextoList(parts);
            return;
        }else if ("vt".equals(parts[0])){
            addTextoList(parts);
            return;
        } else if ("vn".equals(parts[0])){
            addNormalToList(parts);
            return;
        } else if ("g".equals(parts[0])){
            if (parts.length >= 2 && materialNames.get(parts[1]) != null
                   && materialNames.get(parts[1]) != null)
                curGroup = (MaterialGrouping) materialNames.get(parts[1]);
             else
                setDefaultGroup();
            return;
        } else if ("f".equals(parts[0])){
            addFaces(parts);
            return;
        } else if ("mtllib".equals(parts[0])){
            loadMaterials(parts);
            return;
        } else if ("newmtl".equals(parts[0])){
            addMaterial(parts);
            return;
        } else if ("usemtl".equals(parts[0])){
            if (materialNames.get(parts[1])!=null)
                curGroup=(MaterialGrouping) materialNames.get(parts[1]);
            else
                setDefaultGroup();
            return;
        } else if ("Ka".equals(parts[0])){
            curGroup.m.setAmbient(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Kd".equals(parts[0])){
            curGroup.m.setDiffuse(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Ks".equals(parts[0])){
            curGroup.m.setSpecular(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Ns".equals(parts[0])){
            curGroup.m.setShininess(Float.parseFloat(parts[1]));
            return;
        } else if ("d".equals(parts[0])){
            curGroup.m.setAlpha(Float.parseFloat(parts[1]));
            ColorRGBA alpha = new ColorRGBA(1,1,1,curGroup.m.getAlpha());
            curGroup.m.setAmbient(curGroup.m.getAmbient().mult(alpha));
            curGroup.m.setDiffuse(curGroup.m.getDiffuse().mult(alpha));
            curGroup.m.setSpecular(curGroup.m.getSpecular().mult(alpha));
            if (curGroup.m.getAlpha() < 1.0f)
               curGroup.createAlphaState();
            return;
        } else if ("map_d".equals(parts[0])) {
               curGroup.createAlphaState();
               return;
        } else if ("map_Kd".equals(parts[0]) || "map_Ka".equals(parts[0])){
            Texture t=new Texture();
            t.setImageLocation("file:/"+s.substring(6).trim());
            curGroup.ts.setTexture(t);
            curGroup.ts.setEnabled(true);
            return;
        }
    }

Output:
    private void processLine(String s) throws IOException {
        if (s==null) return ;
        if (s.length()==0) return;
        String[] parts=s.split(" ");
        parts=removeEmpty(parts);
        if ("#".equals(parts[0])) return;
        if ("v".equals(parts[0])){
            addVertextoList(parts);
            return;
        }else if ("vt".equals(parts[0])){
            addTextoList(parts);
            return;
        } else if ("vn".equals(parts[0])){
            addNormalToList(parts);
            return;
        } else if ("g".equals(parts[0])){
            if (parts.length >= 2 && materialNames.get(parts[1]) != null
                   && materialNames.get(parts[1]) != null)
                curGroup = (MaterialGrouping) materialNames.get(parts[1]);
             else
                setDefaultGroup();
            return;
        } else if ("f".equals(parts[0])){
            addFaces(parts);
            return;
        } else if ("mtllib".equals(parts[0])){
            loadMaterials(parts);
            return;
        } else if ("newmtl".equals(parts[0])){
            addMaterial(parts);
            return;
        } else if ("usemtl".equals(parts[0])){
            if (materialNames.get(parts[1])!=null)
                curGroup=(MaterialGrouping) materialNames.get(parts[1]);
            else
                setDefaultGroup();
            return;
        } else if ("Ka".equals(parts[0])){
            curGroup.m.setAmbient(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Kd".equals(parts[0])){
            curGroup.m.setDiffuse(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Ks".equals(parts[0])){
            curGroup.m.setSpecular(new ColorRGBA(Float.parseFloat(parts[1]),Float.parseFloat(parts[2]),Float.parseFloat(parts[3]),1));
            return;
        } else if ("Ns".equals(parts[0])){
            curGroup.m.setShininess(Float.parseFloat(parts[1]));
            return;
        } else if ("d".equals(parts[0])){
            curGroup.m.setAlpha(Float.parseFloat(parts[1]));
            ColorRGBA alpha = new ColorRGBA(1,1,1,curGroup.m.getAlpha());
            curGroup.m.setAmbient(curGroup.m.getAmbient().mult(alpha));
            curGroup.m.setDiffuse(curGroup.m.getDiffuse().mult(alpha));
            curGroup.m.setSpecular(curGroup.m.getSpecular().mult(alpha));
            if (curGroup.m.getAlpha() < 1.0f)
               curGroup.createAlphaState();
            return;
        } else if ("map_d".equals(parts[0])) {
               curGroup.createAlphaState();
               return;
        } else if ("map_Kd".equals(parts[0]) || "map_Ka".equals(parts[0])){
            Texture t=new Texture();
            t.setImageLocation("file:/"+s.trim().substring(6));
            curGroup.ts.setTexture(t);
            curGroup.ts.setEnabled(true);
            return;
        }
    }


Input:
	public View getView(int position, View convertView, ViewGroup parent) {
		View res;
		final MagazineModel currentMagazine = magazine.get(position);
		if(convertView == null){
			res = LayoutInflater.from(context).inflate(R.layout.magazine_list_item, null);
		} else {
			res = convertView;
		}
		TextView title = (TextView)res.findViewById(R.id.item_title);
		TextView subtitle = (TextView)res.findViewById(R.id.item_subtitle);
		ImageView thumbnail = (ImageView)res.findViewById(R.id.item_thumbnail);
		title.setText(currentMagazine.getTitle());
		subtitle.setText(currentMagazine.getSubtitle());
		String imagePath = currentMagazine.getPngPath();
		thumbnail.setImageBitmap(BitmapFactory.decodeFile(imagePath));
		Button downloadOrReadButton = (Button)res.findViewById(R.id.item_button_one);
		Button sampleOrDeleteButton = (Button)res.findViewById(R.id.item_button_two);
		if (currentMagazine.isDownloaded()) {
			downloadOrReadButton.setText(context.getResources().getString(
					R.string.read));
			downloadOrReadButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					LibrelioApplication.startPDFActivity(context,
							currentMagazine.getPdfPath());
				}
			});
		} else {
			downloadOrReadButton.setText(context.getResources().getString(
					R.string.download));
			downloadOrReadButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					if(currentMagazine.isPaid()){
						Intent intent = new Intent(context,BillingActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						context.startActivity(intent);
					} else {
						Intent intent = new Intent(context,
								DownloadActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						intent.putExtra(DownloadActivity.IS_SAMPLE_KEY,false);
						intent.putExtra(DownloadActivity.ORIENTATION_KEY,
								context.getResources().getConfiguration().orientation);
						context.startActivity(intent);
					}
				}
			});
		}
		if (!currentMagazine.isPaid() && !currentMagazine.isDownloaded()) {
			sampleOrDeleteButton.setVisibility(View.INVISIBLE);
		} else if (currentMagazine.isDownloaded()) {
				sampleOrDeleteButton.setVisibility(View.VISIBLE);
				sampleOrDeleteButton.setText(context.getResources().getString(
						R.string.delete));
				sampleOrDeleteButton.setOnClickListener(new OnClickListener() {
					@Override
					public void onClick(View v) {
						currentMagazine.delete();
					}
				});
		} else {
			sampleOrDeleteButton.setText(context.getResources().getString(
					R.string.sample));
			sampleOrDeleteButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					File sample = new File(currentMagazine.getSamplePath());
					Log.d(TAG, "test: " + sample.exists() + " "
							+ currentMagazine.isSampleDownloaded());
					if (currentMagazine.isSampleDownloaded()) {
						LibrelioApplication.startPDFActivity(context,
								currentMagazine.getSamplePath());
					} else {
						Intent intent = new Intent(context,
								DownloadActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						intent.putExtra(DownloadActivity.ORIENTATION_KEY,
								context.getResources().getConfiguration().orientation);
						intent.putExtra(DownloadActivity.IS_SAMPLE_KEY,true);
						context.startActivity(intent);
					}
				}
			});
		}
		return res;
	}

Output:
	public View getView(int position, View convertView, ViewGroup parent) {
		View res;
		final MagazineModel currentMagazine = magazine.get(position);
		if(convertView == null){
			res = LayoutInflater.from(context).inflate(R.layout.magazine_list_item, null);
		} else {
			res = convertView;
		}
		TextView title = (TextView)res.findViewById(R.id.item_title);
		TextView subtitle = (TextView)res.findViewById(R.id.item_subtitle);
		ImageView thumbnail = (ImageView)res.findViewById(R.id.item_thumbnail);
		title.setText(currentMagazine.getTitle());
		subtitle.setText(currentMagazine.getSubtitle());
		String imagePath = currentMagazine.getPngPath();
		thumbnail.setImageBitmap(BitmapFactory.decodeFile(imagePath));
		Button downloadOrReadButton = (Button)res.findViewById(R.id.item_button_one);
		Button sampleOrDeleteButton = (Button)res.findViewById(R.id.item_button_two);
		if (currentMagazine.isDownloaded()) {
			downloadOrReadButton.setText(context.getResources().getString(
					R.string.read));
			downloadOrReadButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					LibrelioApplication.startPDFActivity(context,
							currentMagazine.getPdfPath());
				}
			});
		} else {
			downloadOrReadButton.setText(context.getResources().getString(
					R.string.download));
			downloadOrReadButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					if(currentMagazine.isPaid()){
						Intent intent = new Intent(context,BillingActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						context.startActivity(intent);
					} else {
						Intent intent = new Intent(context,
								DownloadActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						intent.putExtra(DownloadActivity.IS_SAMPLE_KEY,false);
						intent.putExtra(DownloadActivity.ORIENTATION_KEY,
								context.getResources().getConfiguration().orientation);
						context.startActivity(intent);
					}
				}
			});
		}
		sampleOrDeleteButton.setVisibility(View.VISIBLE);
		if (!currentMagazine.isPaid() && !currentMagazine.isDownloaded()) {
			sampleOrDeleteButton.setVisibility(View.INVISIBLE);
		} else if (currentMagazine.isDownloaded()) {
				sampleOrDeleteButton.setText(context.getResources().getString(
						R.string.delete));
				sampleOrDeleteButton.setOnClickListener(new OnClickListener() {
					@Override
					public void onClick(View v) {
						currentMagazine.delete();
					}
				});
		} else {
			sampleOrDeleteButton.setText(context.getResources().getString(
					R.string.sample));
			sampleOrDeleteButton.setOnClickListener(new OnClickListener() {
				@Override
				public void onClick(View v) {
					File sample = new File(currentMagazine.getSamplePath());
					Log.d(TAG, "test: " + sample.exists() + " "
							+ currentMagazine.isSampleDownloaded());
					if (currentMagazine.isSampleDownloaded()) {
						LibrelioApplication.startPDFActivity(context,
								currentMagazine.getSamplePath());
					} else {
						Intent intent = new Intent(context,
								DownloadActivity.class);
						intent.putExtra(DownloadActivity.FILE_NAME_KEY,currentMagazine.getFileName());
						intent.putExtra(DownloadActivity.TITLE_KEY,currentMagazine.getTitle());
						intent.putExtra(DownloadActivity.SUBTITLE_KEY,currentMagazine.getSubtitle());
						intent.putExtra(DownloadActivity.ORIENTATION_KEY,
								context.getResources().getConfiguration().orientation);
						intent.putExtra(DownloadActivity.IS_SAMPLE_KEY,true);
						context.startActivity(intent);
					}
				}
			});
		}
		return res;
	}


Input:
    public void run() {
        try {
            while (true) {
                BufferedReader inFromClient = new BufferedReader(new InputStreamReader(socket.getInputStream()));
                DataOutputStream outToClient = new DataOutputStream(socket.getOutputStream());
                String clientMessage = inFromClient.readLine();
                System.out.println("Received: " + clientMessage);
                if (clientMessage.toLowerCase().equals("shutdown")) {
                    outToClient.writeBytes("goodbye");
                    break;
                } else if (clientMessage.toLowerCase().equals("keyval")) {
                    outToClient.writeBytes(Integer.toString(keyVal));
                    break;
                } else if (clientMessage.contains("article")) {
                    String request = clientMessage.substring(8);
                    System.out.println(request);
                    int req = Integer.parseInt(request);
                    System.out.println(req);
                    int key = Integer.parseInt(keylist.getProperty("" + req));
                    System.out.println(key);
                    if (key > keyVal) {
                        outToClient.writeBytes("FAIL: " + nextNode);
                    } else {
                        outToClient.writeBytes("Key Value is: " + key);
                    }
                }
            }
        } catch (IOException ex) {
            System.out.println("Unable to get streams from client");
        } finally {
            try {
                socket.close();
            } catch (IOException ex) {
                ex.printStackTrace();
            }
        }
    }

Output:
    public void run() {
        try {
            while (true) {
                BufferedReader inFromClient = new BufferedReader(new InputStreamReader(socket.getInputStream()));
                DataOutputStream outToClient = new DataOutputStream(socket.getOutputStream());
                String clientMessage = inFromClient.readLine();
                System.out.println("Received: " + clientMessage);
                if (clientMessage.toLowerCase().equals("shutdown")) {
                    outToClient.writeBytes("goodbye");
                    break;
                } else if (clientMessage.toLowerCase().equals("keyval")) {
                    outToClient.writeBytes(Integer.toString(keyVal));
                    break;
                } else if (clientMessage.contains("article")) {
                    String request = clientMessage.substring(8);
                    int req = Integer.parseInt(request);
                    int key = Integer.parseInt(keylist.getProperty("" + req));
                    System.out.println(key);
                    if (key > keyVal) {
                        System.out.println("Failed.");
                        outToClient.writeBytes("FAIL: " + nextNode);
                    } else {
                        System.out.println("It's ours!");
                        outToClient.writeBytes("Key Value is: " + key);
                    }
                }
            }
        } catch (IOException ex) {
            System.out.println("Unable to get streams from client");
        } finally {
            try {
                socket.close();
            } catch (IOException ex) {
                ex.printStackTrace();
            }
        }
    }


Input:
private void writeResponse(HttpServletResponse resp, Result rs, byte[] data, String query, String d, int num)
      throws IOException {
    HttpResponseRecord httpResponseRecord = new HttpResponseRecord(data);
    if (httpResponseRecord.getType().startsWith("text/plain") || !httpResponseRecord.getType().startsWith("text")) {
      resp.setHeader("Content-Type", httpResponseRecord.getType());
      resp.setContentLength(httpResponseRecord.getBodyByte().length);
      resp.getOutputStream().write(httpResponseRecord.getBodyByte());
    } else {
      ArrayList<String> dates = new ArrayList<String>(10);
      for (int i = 0; i < rs.raw().length; i++)
        dates.add(new String(rs.raw()[i].getQualifier()));
      Collections.sort(dates);
      String prevDate = null, nextDate = null;
      for (int i = 1; i < dates.size(); i++){
        if (dates.get(i).compareTo(d) == 0){
          prevDate = dates.get(i - 1);
          if (i + 1 < dates.size())
            nextDate = dates.get(i + 1);
          else
            nextDate = d;
          break;
        }
        if (dates.get(i).compareTo(d) > 0) {
          if ( i > 2)
            prevDate = dates.get(i - 2);
          else
            prevDate = dates.get(i - 1);
          nextDate = dates.get(i);
          break;
        }
      }
      System.setProperty("file.encoding", "UTF8");
      resp.setHeader("Content-Type", httpResponseRecord.getType());
      resp.setCharacterEncoding("UTF-8");
      PrintWriter out = resp.getWriter();
      TextDocument2 t2 = new TextDocument2(null, null, null);
      String bodyContent = new String(httpResponseRecord.getBodyByte(), "UTF8");
      Document doc = Jsoup.parse(bodyContent);
      Element head = doc.select("head").first();
      Element base = doc.select("base").first();
      if(base == null){
        head.prepend("<base id='warcbase-base-added' href='" + query +"'>");
      }
      bodyContent = doc.html();
      bodyContent = t2.fixURLs(bodyContent, query, d);
      doc = Jsoup.parse(bodyContent);
      base = doc.select("base").first();
      if(base != null){
        if(base.attr("id").equals("warcbase-base-added"))
          base.remove();
      }
      head = doc.select("head").first();
      String baseUrl = TextDocument2.SERVER_PREFIX + "warcbase/servlet?date=" + d + "&query=" + query;
      head.prepend("  ");
      Element body = doc.select("body").first();
      body.prepend("

        Warcbase

                <form target=\"_top\" method=\"get\" action=\"" + TextDocument2.SERVER_PREFIX + "warcbase/" + "servlet\" name=\"wmtb\" id=\"wmtb\" style=\"margin:0!important;padding:0!important;\"><input name=\"query\" id=\"wmtbURL\" value=\""
              + query
              + "\" style=\"width:400px;font-size:11px;font-family:'Lucida Grande','Arial',sans-serif;\" onfocus=\"javascript:this.focus();this.select();\" type=\"text\"><input name=\"date\" value=\"\" type=\"hidden\"><input name=\"type\" value=\"replay\" type=\"hidden\"><input name=\"date\" value=\"20120201185436\" type=\"hidden\"><input value=\"Go\" style=\"font-size:11px;font-family:'Lucida Grande','Arial',sans-serif;margin-left:5px;\" type=\"submit\"></form>

                                                   PREV                                     	                         NEXT

                    "
                          + " " + num + " captures"
                          + "
"
                              + dates.get(0).substring(0, 10) + "  -  " + dates.get(dates.size() - 1).substring(0, 10)
                              + "

    	            Close

      ");
      bodyContent = doc.html();
      out.println(bodyContent);
    }

Output:
  private void writeResponse(HttpServletResponse resp, Result rs, byte[] data, String query, String d, int num)
      throws IOException {
    HttpResponseRecord httpResponseRecord = new HttpResponseRecord(data);
    if (httpResponseRecord.getType().startsWith("text/plain") || !httpResponseRecord.getType().startsWith("text")) {
      resp.setHeader("Content-Type", httpResponseRecord.getType());
      resp.setContentLength(httpResponseRecord.getBodyByte().length);
      resp.getOutputStream().write(httpResponseRecord.getBodyByte());
    } else {
      ArrayList<String> dates = new ArrayList<String>(10);
      for (int i = 0; i < rs.raw().length; i++)
        dates.add(new String(rs.raw()[i].getQualifier()));
      Collections.sort(dates);
      String prevDate = null, nextDate = null;
      for (int i = 1; i < dates.size(); i++){
        if (dates.get(i).compareTo(d) == 0){
          prevDate = dates.get(i - 1);
          if (i + 1 < dates.size())
            nextDate = dates.get(i + 1);
          else
            nextDate = d;
          break;
        }
        if (dates.get(i).compareTo(d) > 0) {
          if ( i > 2)
            prevDate = dates.get(i - 2);
          else
            prevDate = dates.get(i - 1);
          nextDate = dates.get(i);
          break;
        }
      }
      System.setProperty("file.encoding", "UTF8");
      resp.setHeader("Content-Type", httpResponseRecord.getType());
      resp.setCharacterEncoding("UTF-8");
      PrintWriter out = resp.getWriter();
      TextDocument2 t2 = new TextDocument2(null, null, null);
      String bodyContent = new String(httpResponseRecord.getBodyByte(), "UTF8");
      Document doc = Jsoup.parse(bodyContent);
      Element head = doc.select("head").first();
      Element base = doc.select("base").first();
      if(base == null){
        head.prepend("<base id='warcbase-base-added' href='" + query +"'>");
      }
      bodyContent = doc.html();
      bodyContent = t2.fixURLs(bodyContent, query, d);
      doc = Jsoup.parse(bodyContent);
      base = doc.select("base").first();
      if(base != null){
        if(base.attr("id").equals("warcbase-base-added"))
          base.remove();
      }
      head = doc.select("head").first();
      String baseUrl = TextDocument2.SERVER_PREFIX + "warcbase/servlet?date=" + d + "&query=" + query;
      head.prepend("<script type=\"text/javascript\"> function initYTVideo(id) {  _wmVideos_.init('/web/', id); } </script>  <script> function $(a){return document.getElementById(a)};     function addLoadEvent(a){if(window.addEventListener)addEventListener('load',a,false);else if(window.attachEvent)attachEvent('onload',a)} </script>");
      Element body = doc.select("body").first();
      body.prepend("<div id=\"wm-ipp\" style=\"display: block; position: relative; padding: 0px 5px; min-height: 70px; min-width: 800px; z-index: 9000;\"><div id=\"wm-ipp-inside\" style=\"position:fixed;padding:0!important;margin:0!important;width:97%;min-width:780px;border:5px solid #000;border-top:none;background-image:url(" + TextDocument2.SERVER_PREFIX + "warcbase/" + "images/wm_tb_bk_trns.png);text-align:center;-moz-box-shadow:1px 1px 3px #333;-webkit-box-shadow:1px 1px 3px #333;box-shadow:1px 1px 3px #333;font-size:11px!important;font-family:'Lucida Grande','Arial',sans-serif!important;\">    <table style=\"border-collapse:collapse;margin:0;padding:0;width:100%;\"><tbody><tr>    <td style=\"padding:10px;vertical-align:top;min-width:110px;\">    <a href=\""
          + TextDocument2.SERVER_PREFIX + "warcbase"
          + "\" title=\"Warcbase home page\" style=\"background-color:transparent;border:none;\">Warcbase</a>    </td>            <td style=\"padding:0!important;text-align:center;vertical-align:top;width:100%;\">         <table style=\"border-collapse:collapse;margin:0 auto;padding:0;width:570px;\"><tbody><tr>        <td style=\"padding:3px 0;\" colspan=\"2\">        <form target=\"_top\" method=\"get\" action=\"" + TextDocument2.SERVER_PREFIX + "warcbase/" + "servlet\" name=\"wmtb\" id=\"wmtb\" style=\"margin:0!important;padding:0!important;\"><input name=\"query\" id=\"wmtbURL\" value=\""
              + query
              + "\" style=\"width:400px;font-size:11px;font-family:'Lucida Grande','Arial',sans-serif;\" onfocus=\"javascript:this.focus();this.select();\" type=\"text\"><input name=\"date\" value=\"\" type=\"hidden\"><input name=\"type\" value=\"replay\" type=\"hidden\"><input name=\"date\" value=\"20120201185436\" type=\"hidden\"><input value=\"Go\" style=\"font-size:11px;font-family:'Lucida Grande','Arial',sans-serif;margin-left:5px;\" type=\"submit\"><span id=\"wm_tb_options\" style=\"display:block;\"></span></form>        </td>        <td style=\"vertical-align:bottom;padding:5px 0 0 0!important;\" rowspan=\"2\">            <table style=\"border-collapse:collapse;width:110px;color:#99a;font-family:'Helvetica','Lucida Grande','Arial',sans-serif;\"><tbody>                  <!-- NEXT/PREV MONTH NAV AND MONTH INDICATOR -->            <tr style=\"width:110px;height:16px;font-size:10px!important;\">              <td style=\"padding-right:9px;font-size:11px!important;font-weight:bold;text-transform:uppercase;text-align:right;white-space:nowrap;overflow:visible;\" nowrap=\"nowrap\">                                     <strong>PREV</strong>                                     </td>         <td style=\"padding-left:9px;font-size:11px!important;font-weight:bold;text-transform:uppercase;white-space:nowrap;overflow:visible;\" nowrap=\"nowrap\">                <strong>NEXT</strong>                                    </td>            </tr>             <!-- NEXT/PREV CAPTURE NAV AND DAY OF MONTH INDICATOR -->            <tr>                <td style=\"padding-right:9px;white-space:nowrap;overflow:visible;text-align:right!important;vertical-align:middle!important;\" nowrap=\"nowrap\">                                    <a href=\""
                  + TextDocument2.SERVER_PREFIX + "warcbase/servlet?date=" + prevDate + "&query=" + query
                  + "\" title=\""
                  + prevDate
                  + "\" style=\"background-color:transparent;border:none;\"><img src=\"" + TextDocument2.SERVER_PREFIX + "warcbase/" + "images/wm_tb_prv_on.png\" alt=\"Previous capture\" border=\"0\" height=\"16\" width=\"14\"></a>                                    </td>         <td style=\"padding-left:9px;white-space:nowrap;overflow:visible;text-align:left!important;vertical-align:middle!important;\" nowrap=\"nowrap\">                                    <a href=\""
                      + TextDocument2.SERVER_PREFIX + "warcbase/servlet?date=" + nextDate + "&query=" + query
                      + "\" title=\""
                      + nextDate
                      + "\" style=\"background-color:transparent;border:none;\"><img src=\"" + TextDocument2.SERVER_PREFIX + "warcbase/" + "images/wm_tb_nxt_on.png\" alt=\"Next capture\" border=\"0\" height=\"16\" width=\"14\"></a>                              </td>            </tr>             </tbody></table>        </td>         </tr>        <tr>        <td style=\"vertical-align:middle;padding:0!important;\">            <strong>"
                          + " " + num + " captures"
                          + "</strong>            <div style=\"margin:0!important;padding:0!important;color:#666;font-size:9px;padding-top:2px!important;white-space:nowrap;\" title=\"Timespan for captures of this URL\">"
                              + dates.get(0).substring(0, 10) + "  -  " + dates.get(dates.size() - 1).substring(0, 10)
                              + "</div>        </td>                </tr></tbody></table>    </td>    <td style=\"text-align:right;padding:5px;width:65px;font-size:11px!important;\">        <a href=\"javascript:;\" onclick=\"document.getElementById('wm-ipp').style.display='none';\" style=\"display:block;padding-right:18px;background:url(" + TextDocument2.SERVER_PREFIX + "warcbase/" + "images/wm_tb_close.png) no-repeat 100% 0;color:#33f;font-family:'Lucida Grande','Arial',sans-serif;margin-bottom:23px;background-color:transparent;border:none;\" title=\"Close the toolbar\">Close</a>            </td>    </tr></tbody></table>  </div> </div>      <style type=\"text/css\">body{margin-top:0!important;padding-top:0!important;min-width:800px!important;}#wm-ipp a:hover{text-decoration:underline!important;}</style>");
      bodyContent = doc.html();
      out.println(bodyContent);
    }


Input:
    private synchronized Class inject(String className, byte[] image) {
        Class c = classes.get(className);
        if(c==null) {
            try {
                c = (Class)defineClass.invoke(parent,className.replace('/','.'),image,0,image.length);
                resolveClass.invoke(parent,c);
            } catch (IllegalAccessException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            } catch (InvocationTargetException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            } catch (SecurityException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            }
            classes.put(className,c);
        }
        return c;
    }

Output:
    private synchronized Class inject(String className, byte[] image) {
        Class c = classes.get(className);
        if(c==null) {
            try {
                c = (Class)defineClass.invoke(parent,className.replace('/','.'),image,0,image.length);
                resolveClass.invoke(parent,c);
            } catch (IllegalAccessException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            } catch (InvocationTargetException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            } catch (SecurityException e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            } catch (LinkageError e) {
                logger.log(Level.FINE,"Unable to inject "+className,e);
                return null;
            }
            classes.put(className,c);
        }
        return c;
    }