content
stringlengths
40
137k
"public void startEntity(String name) throws SAXException {\n if (null != lexicalHandler) {\n lexicalHandler.startEntity(name);\n }\n}\n"
"public static void main(String[] args) throws Exception {\n Injector injector = Guice.createInjector(Stage.PRODUCTION, new LifecycleModule(), new DummyServiceLocatorModule(), new EmbeddedJettyJerseyModule(), new RESTEventReceiverModule(CollectorEventProcessor.class, \"String_Node_Str\"), new UDPEventReceiverModule(), new AbstractModule() {\n\n protected void configure() {\n bind(MBeanServer.class).toInstance(ManagementFactory.getPlatformMBeanServer());\n }\n }, new RMIModule(), new CollectorModule());\n EventCollectorServer server = injector.getInstance(EventCollectorServer.class);\n server.run();\n}\n"
"private void onClickOtaEndButton() {\n if (DBG)\n log(\"String_Node_Str\");\n if (!mApplication.cdmaOtaProvisionData.inOtaSpcState) {\n if (PhoneUtils.hangup(mApplication.phone) == false) {\n setSpeaker(false);\n mInCallScreen.handleOtaCallEnd();\n }\n }\n}\n"
"public synchronized void render(GL2 gl) {\n if (neighborSetID == -1 || similarities == null)\n return;\n float yOffset = 0;\n for (GLBrick brick : neighborBrickOrder) {\n int foreignGroupID = brick.getGroup().getGroupID();\n float similarity = similarities[foreignGroupID];\n float height = similarity * y;\n gl.glBegin(GL2.GL_POLYGON);\n gl.glColor3f(0, 0, 0);\n gl.glVertex3f(0, yOffset, 0);\n gl.glVertex3f(x, yOffset, 0);\n if (brick.getContentGroupSelectionManager().checkStatus(SelectionType.SELECTION, brick.getGroup().getID()))\n gl.glColor4fv(SelectionType.SELECTION.getColor(), 0);\n else\n gl.glColor3f(1, 1, 1);\n gl.glVertex3f(x, yOffset + height, 0);\n gl.glVertex3f(0, yOffset + height, 0);\n gl.glEnd();\n yOffset += height;\n if (yOffset > y + 0.001f)\n GLHelperFunctions.drawSmallPointAt(gl, x, yOffset, 0);\n }\n}\n"
"public void getStr(int col, CharSink sink) {\n rec.getStr(col, sink);\n}\n"
"public void run() {\n positionsLock.readLock().lock();\n try {\n int size = positions.size() * 3;\n float[] vertices;\n vertexVBO.lock();\n try {\n vertices = vertexVBO.getBuffer();\n if (vertices == null || vertices.length != size) {\n vertices = new float[size];\n }\n calculateVertices(dc, vertices);\n vertexVBO.setBuffer(vertices);\n } finally {\n vertexVBO.unlock();\n }\n calculateVertices(dc, vertices);\n vertexVBO.setBuffer(vertices);\n if (willCalculateNormals()) {\n float[] normals = normalVBO.getBuffer();\n if (normals == null || normals.length != size) {\n normals = new float[size];\n }\n calculateNormals(vertices, normals);\n normalVBO.setBuffer(normals);\n }\n Sphere temp = boundingSphere;\n boundingSphere = modBoundingSphere;\n modBoundingSphere = temp;\n } finally {\n positionsLock.readLock().unlock();\n }\n if (lastLayer != null && !followTerrain) {\n lastLayer.firePropertyChange(AVKey.LAYER, null, lastLayer);\n }\n}\n"
"public static ColumnsInfo createTable(ITableContent table, int width, int dpi) {\n int tableWidth = getElementWidth(table, width, dpi);\n int columnCount = table.getColumnCount();\n if (columnCount == 0) {\n return null;\n }\n int[] columns = new int[columnCount];\n int unassignedCount = 0;\n int totalAssigned = 0;\n for (int i = 0; i < columnCount; i++) {\n DimensionType value = table.getColumn(i).getWidth();\n if (value == null) {\n columns[i] = -1;\n unassignedCount++;\n } else {\n columns[i] = ExcelUtil.convertDimensionType(value, tableWidth, dpi);\n totalAssigned += columns[i];\n }\n }\n int leftWidth = tableWidth - totalAssigned;\n if (leftWidth > 0 && unassignedCount == 0 && table.getWidth() != null) {\n int totalResized = 0;\n for (int i = 0; i < columnCount - 1; i++) {\n columns[i] = resize(columns[i], totalAssigned, leftWidth);\n totalResized += columns[i];\n }\n columns[columnCount - 1] = tableWidth - totalResized;\n } else if (leftWidth < 0 && unassignedCount > 0) {\n int totalResized = 0;\n int lastAssignedIndex = 0;\n for (int i = 0; i < columnCount; i++) {\n if (columns[i] == -1) {\n columns[i] = 0;\n } else {\n columns[i] = resize(columns[i], totalAssigned, leftWidth);\n lastAssignedIndex = i;\n }\n totalResized += columns[i];\n }\n columns[lastAssignedIndex] += tableWidth - totalResized;\n } else if (leftWidth >= 0 && unassignedCount > 0) {\n int per = (int) leftWidth / unassignedCount;\n int index = 0;\n for (int i = 0; i < columns.length; i++) {\n if (columns[i] == -1) {\n columns[i] = per;\n index = i;\n }\n }\n columns[index] = leftWidth - per * (unassignedCount - 1);\n }\n return new ColumnsInfo(columns);\n}\n"
"public void testInsert() {\n Delete.table(InsertModel.class);\n Insert<InsertModel> insert = Insert.into(InsertModel.class).orFail().columns(InsertModel$Table.NAME, InsertModel$Table.VALUE).values(\"String_Node_Str\", \"String_Node_Str\");\n assertEquals(\"String_Node_Str\", insert.getQuery());\n FlowManager.getDatabase(TestDatabase.NAME).getWritableDatabase().execSQL(insert.getQuery());\n InsertModel model = new Select().from(InsertModel.class).where(Condition.column(InsertModel$Table.NAME).is(\"String_Node_Str\")).querySingle();\n assertNotNull(model);\n insert = new Insert<>(InsertModel.class).orAbort().values(\"String_Node_Str\", \"String_Node_Str\");\n assertEquals(\"String_Node_Str\", insert.getQuery());\n FlowManager.getDatabase(TestDatabase.NAME).getWritableDatabase().execSQL(insert.getQuery());\n model = new Select().from(InsertModel.class).where(Condition.column(InsertModel$Table.NAME).is(\"String_Node_Str\")).querySingle();\n assertNotNull(model);\n}\n"
"public static int[] shape(int[] shape, NDArrayIndex... indices) {\n return shape(shape, new int[shape.length], indices);\n}\n"
"public void cmdXkcd(Context ctx) {\n if (ctx.rawArgs.length() < 1) {\n ctx.send(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\").queue();\n return;\n }\n String first = ctx.args.get(0);\n String second = \"String_Node_Str\";\n try {\n second = ctx.args.get(1);\n } catch (IndexOutOfBoundsException e) {\n }\n String comicTitle;\n String comicUrl;\n String comicDesc;\n int comicNum;\n if (first.equalsIgnoreCase(\"String_Node_Str\")) {\n try {\n comicNum = Unirest.get(\"String_Node_Str\").asJson().getBody().getObject().getInt(\"String_Node_Str\");\n } catch (UnirestException e) {\n logger.error(\"String_Node_Str\", e);\n ctx.send(\"String_Node_Str\").queue();\n return;\n }\n } else if (first.equalsIgnoreCase(\"String_Node_Str\")) {\n try {\n comicNum = randint(1, Unirest.get(\"String_Node_Str\").asJson().getBody().getObject().getInt(\"String_Node_Str\") + 1);\n } catch (UnirestException e) {\n logger.error(\"String_Node_Str\", e);\n ctx.send(\"String_Node_Str\").queue();\n return;\n }\n } else if ((first.equalsIgnoreCase(\"String_Node_Str\") && second.matches(\"String_Node_Str\")) || first.matches(\"String_Node_Str\")) {\n try {\n int max = Unirest.get(\"String_Node_Str\").asJson().getBody().getObject().getInt(\"String_Node_Str\");\n int requested;\n try {\n requested = Integer.parseInt(first);\n } catch (NumberFormatException e) {\n requested = Integer.parseInt(second);\n }\n if (requested > 0 && requested <= max) {\n comicNum = requested;\n } else {\n ctx.send(\"String_Node_Str\" + max + '.').queue();\n return;\n }\n } catch (UnirestException e) {\n logger.error(\"String_Node_Str\", e);\n ctx.send(\"String_Node_Str\").queue();\n return;\n }\n } else {\n ctx.send(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\").queue();\n return;\n }\n try {\n JSONObject resp = Unirest.get(\"String_Node_Str\" + comicNum + \"String_Node_Str\").asJson().getBody().getObject();\n comicTitle = resp.getString(\"String_Node_Str\");\n comicDesc = resp.getString(\"String_Node_Str\");\n comicUrl = resp.getString(\"String_Node_Str\");\n } catch (UnirestException e) {\n logger.error(\"String_Node_Str\", e);\n ctx.send(\"String_Node_Str\").queue();\n return;\n }\n EmbedBuilder emb = new EmbedBuilder().setColor(randomColor()).setAuthor(comicTitle, \"String_Node_Str\" + comicNum, null).setImage(comicUrl).setFooter(comicDesc, null);\n ctx.send(emb.build()).queue();\n}\n"
"private int parseIntParam(String name, String value) throws JATEException {\n try {\n return Integer.parseInt(value);\n } catch (NumberFormatException nfe) {\n String msg = String.format(\"String_Node_Str\" + \"String_Node_Str\", name, value);\n log.error(msg);\n throw new JATEException(msg);\n }\n}\n"
"private void drawDiagonalLine(ICellContent cell, double cellWidth) {\n DiagonalLineInfo diagonalLineInfo = new DiagonalLineInfo();\n int diagonalWidth = PropertyUtil.getDimensionValue(cell, cell.getDiagonalWidth(), (int) cellWidth) / 1000;\n diagonalLineInfo.setDiagonalLine(cell.getDiagonalNumber(), cell.getDiagonalStyle(), diagonalWidth);\n int antidiagonalWidth = PropertyUtil.getDimensionValue(cell, cell.getAntidiagonalWidth(), (int) cellWidth) / 1000;\n diagonalLineInfo.setAntidiagonalLine(cell.getAntidiagonalNumber(), cell.getAntidiagonalStyle(), antidiagonalWidth);\n int cellHeight = WordUtil.convertTo(getCellHeight(cell), 0) / 20;\n diagonalLineInfo.setCoordinateSize(cellWidth, cellHeight);\n String lineColor = WordUtil.parseColor(cell.getComputedStyle().getColor());\n diagonalLineInfo.setColor(lineColor);\n wordWriter.drawDiagonalLine(diagonalLineInfo);\n}\n"
"public String toString() {\n StringBuilder builder = new StringBuilder();\n builder.append(name).append(\"String_Node_Str\").append(value);\n if (!StringUtils.isBlank(comment)) {\n builder.append(\"String_Node_Str\").append(comment);\n }\n}\n"
"public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n TextView textView = new TextView(getActivity());\n textView.setText(\"String_Node_Str\");\n return textView;\n}\n"
"protected static void createTrigger(Connection conn, String schema, String table) throws SQLException {\n Statement stat = conn.createStatement();\n String trigger = StringUtils.quoteIdentifier(schema) + \"String_Node_Str\" + StringUtils.quoteIdentifier(TRIGGER_PREFIX + table);\n stat.execute(\"String_Node_Str\" + trigger);\n StringBuilder buff = new StringBuilder(\"String_Node_Str\");\n buff.append(trigger).append(\"String_Node_Str\").append(StringUtils.quoteIdentifier(schema)).append('.').append(StringUtils.quoteIdentifier(table)).append(\"String_Node_Str\").append(FullTextLucene.FullTextTrigger.class.getName()).append('\\\"');\n stat.execute(buff.toString());\n}\n"
"private void smartAppendExclusive(short[] vl, short val) {\n int oldend;\n if ((nbrruns == 0) || (BufferUtil.toIntUnsigned(val) > (oldend = BufferUtil.toIntUnsigned(getValue(nbrruns - 1)) + BufferUtil.toIntUnsigned(getLength(nbrruns - 1)) + 1))) {\n vl[2 * nbrruns] = val;\n vl[2 * nbrruns + 1] = 0;\n nbrruns++;\n return;\n }\n int newend = BufferUtil.toIntUnsigned(val) + 1;\n if (BufferUtil.toIntUnsigned(val) == BufferUtil.toIntUnsigned(getValue(nbrruns - 1))) {\n if (newend != oldend) {\n setValue(nbrruns - 1, (short) newend);\n setLength(nbrruns - 1, (short) (oldend - newend - 1));\n return;\n } else {\n nbrruns--;\n return;\n }\n }\n setLength(nbrruns - 1, (short) (val - BufferUtil.toIntUnsigned(getValue(nbrruns - 1)) - 1));\n if (newend < oldend) {\n setValue(nbrruns, (short) newend);\n setLength(nbrruns, (short) (oldend - newend - 1));\n nbrruns++;\n }\n}\n"
"public String RunSelfForever() {\n System.out.println(\"String_Node_Str\");\n throw new RuntimeException(\"String_Node_Str\");\n}\n"
"private static void countReadsInFeatures(final File samFile, final InputStream gffFile, final File outFile, final StrandUsage stranded, final OverlapMode overlapMode, final String featureType, final String attributeId, final boolean quiet, final int minAverageQual, final File samOutFile, Reporter reporter, String counterGroup) throws EoulsanException, IOException, BadBioEntryException {\n final GenomicArray<String> features = new GenomicArray<String>();\n final Map<String, Integer> counts = Utils.newHashMap();\n final Writer writer = FileUtils.createBufferedWriter(outFile);\n boolean pairedEnd = false;\n final GFFReader gffReader = new GFFReader(gffFile);\n for (final GFFEntry gff : gffReader) {\n if (featureType.equals(gff.getType())) {\n final String featureId = gff.getAttributeValue(attributeId);\n if (featureId == null) {\n gffReader.close();\n writer.close();\n throw new EoulsanException(\"String_Node_Str\" + featureType + \"String_Node_Str\" + attributeId + \"String_Node_Str\");\n }\n if ((stranded == StrandUsage.YES || stranded == StrandUsage.REVERSE) && '.' == gff.getStrand()) {\n gffReader.close();\n writer.close();\n throw new EoulsanException(\"String_Node_Str\" + featureType + \"String_Node_Str\" + \"String_Node_Str\");\n }\n features.addEntry(new GenomicInterval(gff, stranded.isSaveStrandInfo()), featureId);\n counts.put(featureId, 0);\n }\n }\n gffReader.throwException();\n gffReader.close();\n if (counts.size() == 0) {\n writer.close();\n throw new EoulsanException(\"String_Node_Str\" + featureType + \"String_Node_Str\");\n }\n List<GenomicInterval> ivSeq = new ArrayList<GenomicInterval>();\n final SAMFileReader inputSam = new SAMFileReader(samFile);\n final SAMFileReader input = new SAMFileReader(samFile);\n SAMRecordIterator samIterator = input.iterator();\n SAMRecord firstRecord = samIterator.next();\n if (firstRecord.getReadPairedFlag())\n pairedEnd = true;\n input.close();\n int empty = 0;\n int ambiguous = 0;\n int notaligned = 0;\n int lowqual = 0;\n int nonunique = 0;\n int i = 0;\n SAMRecord sam1 = null, sam2 = null;\n for (final SAMRecord samRecord : inputSam) {\n reporter.incrCounter(counterGroup, ExpressionCounters.TOTAL_ALIGNMENTS_COUNTER.counterName(), 1);\n i++;\n if (i % 1000000 == 0)\n System.out.println(i + \"String_Node_Str\");\n if (!pairedEnd) {\n ivSeq.clear();\n if (samRecord.getReadUnmappedFlag()) {\n notaligned++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n if (samRecord.getAttribute(\"String_Node_Str\") != null && samRecord.getIntegerAttribute(\"String_Node_Str\") > 1) {\n nonunique++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n if (samRecord.getMappingQuality() < minAverageQual) {\n lowqual++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n ivSeq.addAll(addIntervals(samRecord, stranded));\n } else {\n if (sam1 != null && sam2 != null) {\n sam1 = null;\n sam2 = null;\n ivSeq.clear();\n }\n if (samRecord.getFirstOfPairFlag())\n sam1 = samRecord;\n else\n sam2 = samRecord;\n if (sam1 == null || sam2 == null)\n continue;\n if (!sam1.getReadName().equals(sam2.getReadName())) {\n sam1 = sam2;\n sam2 = null;\n continue;\n }\n if (sam1 != null && !sam1.getReadUnmappedFlag()) {\n ivSeq.addAll(addIntervals(sam1, stranded));\n }\n if (sam2 != null && !sam2.getReadUnmappedFlag()) {\n ivSeq.addAll(addIntervals(sam2, stranded));\n }\n if (sam1.getReadUnmappedFlag() && sam2.getReadUnmappedFlag()) {\n notaligned++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n if ((sam1.getAttribute(\"String_Node_Str\") != null && sam1.getIntegerAttribute(\"String_Node_Str\") > 1) || (sam2.getAttribute(\"String_Node_Str\") != null && sam2.getIntegerAttribute(\"String_Node_Str\") > 1)) {\n nonunique++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n if (sam1.getMappingQuality() < minAverageQual || sam2.getMappingQuality() < minAverageQual) {\n lowqual++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n continue;\n }\n }\n Set<String> fs = null;\n fs = featuresOverlapped(ivSeq, features, overlapMode, stranded);\n if (fs == null)\n fs = new HashSet<String>();\n switch(fs.size()) {\n case 0:\n empty++;\n reporter.incrCounter(counterGroup, ExpressionCounters.UNMAPPED_READS_COUNTER.counterName(), 1);\n break;\n case 1:\n final String id = fs.iterator().next();\n counts.put(id, counts.get(id) + 1);\n break;\n default:\n ambiguous++;\n reporter.incrCounter(counterGroup, ExpressionCounters.ELIMINATED_READS_COUNTER.counterName(), 1);\n break;\n }\n }\n inputSam.close();\n final List<String> keysSorted = new ArrayList<String>(counts.keySet());\n Collections.sort(keysSorted);\n for (String key : keysSorted) {\n writer.write(key + \"String_Node_Str\" + counts.get(key) + \"String_Node_Str\");\n }\n writer.write(\"String_Node_Str\" + empty + '\\n');\n writer.write(\"String_Node_Str\" + ambiguous + '\\n');\n writer.write(\"String_Node_Str\" + lowqual + '\\n');\n writer.write(\"String_Node_Str\" + notaligned + '\\n');\n writer.write(\"String_Node_Str\" + nonunique + '\\n');\n writer.close();\n}\n"
"private String procedure(Procedure procedure) {\n if (!includeProcedures)\n return null;\n if (ignoreTeiidProcedures && isTeiidProcedure(procedure.getName()))\n return null;\n StringBuilder sb = new StringBuilder();\n boolean isFunction = procedure.isFunction();\n if (isFunction) {\n if (isVirtual)\n sb.append(CREATE_VIRTUAL_FUNCTION).append(SPACE);\n else\n sb.append(CREATE_FOREIGN_FUNCTION).append(SPACE);\n } else {\n if (isVirtual)\n sb.append(CREATE_VIRTUAL_PROCEDURE).append(SPACE);\n else\n sb.append(CREATE_FOREIGN_PROCEDURE).append(SPACE);\n }\n sb.append(getName(procedure));\n sb.append(SPACE + OPEN_BRACKET);\n List<ProcedureParameter> params = procedure.getParameters();\n int nParams = params.size();\n int count = 0;\n for (ProcedureParameter param : params) {\n String paramStr = getParameterDdl(param);\n count++;\n sb.append(TAB).append(paramStr);\n String options = getOptions(param);\n if (!StringUtilities.isEmpty(options)) {\n sb.append(SPACE).append(options);\n }\n if (count < nParams)\n sb.append(COMMA + SPACE);\n }\n sb.append(CLOSE_BRACKET);\n if (procedure.getResult() != null) {\n sb.append(SPACE + RETURNS);\n String options = getOptions(procedure.getResult());\n if (!StringUtilities.isEmpty(options)) {\n sb.append(SPACE).append(options);\n }\n sb.append(SPACE + TABLE + SPACE);\n sb.append(OPEN_BRACKET);\n count = 0;\n int nCols = procedure.getResult().getColumns().size();\n for (Object col : procedure.getResult().getColumns()) {\n Column nextCol = (Column) col;\n count++;\n String columnStr = getColumnDdl(nextCol);\n sb.append(columnStr);\n if (count < nCols)\n sb.append(COMMA + SPACE);\n }\n sb.append(CLOSE_BRACKET);\n }\n String options = getProcedureOptions(procedure);\n if (!StringUtilities.isEmpty(options)) {\n sb.append(NEW_LINE);\n sb.append(SPACE).append(options);\n }\n if (isVirtual && !isFunction) {\n TransformationMappingRoot tRoot = (TransformationMappingRoot) TransformationHelper.getTransformationMappingRoot(procedure);\n String sqlString = TransformationHelper.getSelectSqlString(tRoot).replace(CREATE_VIRTUAL_PROCEDURE, StringConstants.EMPTY_STRING);\n if (sqlString != null) {\n if (sqlString.indexOf('\\n') == 0) {\n sqlString = sqlString.replace(StringConstants.NEW_LINE, StringConstants.EMPTY_STRING);\n }\n sb.append(NEW_LINE + TAB).append(Reserved.AS).append(NEW_LINE).append(sqlString);\n if (!sqlString.endsWith(SEMI_COLON))\n sb.append(SEMI_COLON);\n sb.append(NEW_LINE);\n }\n } else {\n sb.append(SEMI_COLON + NEW_LINE);\n }\n return sb.toString();\n}\n"
"public static Set<Vertex> verticesByFullUris(Graph graph, Collection<String> fullUris) {\n Set<Vertex> vertices = new HashSet<Vertex>();\n for (String fullUri : fullUris) {\n Vertex v = vertexByFullUri(graph, fullUri);\n if (v != null)\n vertices.add(v);\n }\n return vertices;\n}\n"
"public Monitor createMonitor(Trajectory trajectory, Formula property) {\n if (trajectory.getLastPoint().getTime() < property.getTimeNeeded()) {\n throw new IllegalArgumentException(\"String_Node_Str\" + property + \"String_Node_Str\" + property.getTimeNeeded() + \"String_Node_Str\" + trajectory.getLastPoint().getTime() + \"String_Node_Str\" + trajectory.getFirstPoint() + \"String_Node_Str\");\n }\n switch(property.getType()) {\n case AND:\n return new AndMonitor(property, createMonitor(trajectory, property.getSubformula(0)), createMonitor(trajectory, property.getSubformula(1)));\n case FUTURE:\n return new FutureMonitor(property, createMonitor(trajectory, property.getSubformula(0)), ((FutureFormula) property).getInterval());\n case GLOBALLY:\n return new GloballyMonitor(property, createMonitor(trajectory, property.getSubformula(0)), ((GloballyFormula) property).getInterval());\n case NOT:\n return new NotMonitor(property, createMonitor(trajectory, property.getSubformula(0)));\n case OR:\n return new OrMonitor(property, createMonitor(trajectory, property.getSubformula(0)), createMonitor(trajectory, property.getSubformula(1)));\n case PREDICATE:\n return new PredicateMonitor(property, trajectory, (Predicate) property);\n case UNTIL:\n return new UntilMonitor(property, createMonitor(trajectory, property.getSubformula(0)), createMonitor(trajectory, property.getSubformula(1)), ((UntilFormula) property).getInterval());\n default:\n throw new UnsupportedOperationException(\"String_Node_Str\" + property.getType() + \"String_Node_Str\");\n }\n}\n"
"private static void editChatLineList(List<ChatLine> lineList, Function<Message, Boolean> toReplace, Message... replacements) {\n ListIterator<ChatLine> chatLineIterator = lineList.listIterator();\n while (chatLineIterator.hasNext()) {\n ChatLine chatLine = chatLineIterator.next();\n boolean result = toReplace.apply(new Message(chatLine.getChatComponent()).setChatLineId(chatLine.getChatLineID()));\n if (!result) {\n continue;\n }\n chatLineIterator.remove();\n for (Message message : replacements) {\n int lineId = message.getChatLineId() == -1 ? 0 : message.getChatLineId();\n ChatLine newChatLine = new ChatLine(chatLine.getUpdatedCounter(), message.getChatMessage(), lineId);\n chatLineIterator.add(newChatLine);\n }\n }\n}\n"
"protected String computeKey() {\n Fingerprint f = new Fingerprint();\n f.addString(GUID);\n f.addInt(privateHeaders.size());\n for (Artifact artifact : privateHeaders) {\n f.addPath(artifact.getExecPath());\n }\n f.addInt(publicHeaders.size());\n for (Artifact artifact : publicHeaders) {\n f.addPath(artifact.getRootRelativePath());\n }\n f.addInt(dependencies.size());\n for (CppModuleMap dep : dependencies) {\n f.addPath(dep.getArtifact().getExecPath());\n }\n f.addInt(additionalExportedHeaders.size());\n for (PathFragment path : additionalExportedHeaders) {\n f.addPath(path);\n }\n f.addPath(cppModuleMap.getArtifact().getExecPath());\n f.addString(cppModuleMap.getName());\n f.addBoolean(moduleMapHomeIsCwd);\n f.addBoolean(compiledModule);\n f.addBoolean(generateSubmodules);\n f.addBoolean(externDependencies);\n return f.hexDigestAndReset();\n}\n"
"public Object exec(List args) throws TemplateModelException {\n if (args.size() != 1) {\n throw new TemplateModelException(\"String_Node_Str\" + biName + \"String_Node_Str\" + args.size() + \"String_Node_Str\");\n }\n TemplateModel tzArgTM = (TemplateModel) args.get(0);\n TimeZone tzArg;\n Object adaptedObj;\n if (tzArgTM instanceof AdapterTemplateModel && (adaptedObj = ((AdapterTemplateModel) tzArgTM).getAdaptedObject(TimeZone.class)) instanceof TimeZone) {\n tzArg = (TimeZone) adaptedObj;\n } else if (tzArgTM instanceof TemplateScalarModel) {\n String tzName = ((TemplateScalarModel) tzArgTM).getAsString();\n try {\n tzArg = DateUtil.getTimeZone(tzName);\n } catch (UnrecognizedTimeZoneException e) {\n throw new TemplateModelException(\"String_Node_Str\" + biName + \"String_Node_Str\" + StringUtil.jQuote(tzName));\n }\n } else {\n throw new TemplateModelException(\"String_Node_Str\" + biName + \"String_Node_Str\" + \"String_Node_Str\" + (tzArgTM != null ? tzArgTM.getClass().getName() : \"String_Node_Str\") + \"String_Node_Str\");\n }\n return new SimpleScalar(DateUtil.dateToISO8601String(date, dateType != TemplateDateModel.TIME, dateType != TemplateDateModel.DATE, showOffset && dateType != TemplateDateModel.DATE, accuracy, tzArg, env.getISOBuiltInCalendar()));\n}\n"
"public int getIndex(short x) {\n return this.binarySearch(0, size, x);\n}\n"
"protected boolean containment(EObject eObject) {\n return (eObject instanceof Resource) || (eObject instanceof System) || (eObject instanceof TasksGroup) || (eObject instanceof Task) || (eObject instanceof Loop) || (eObject instanceof TaskReference);\n}\n"
"private int getAcceptCount(PrepareState proposalState) {\n int acceptCount = 0;\n PrepareNumber prepareNumber = proposalState.getPrepareRequest().getNumber();\n for (PrepareResponse prepareResponse : proposalState.getProposalResponses()) {\n if (prepareNumber.compareTo(prepareResponse.getMaxNumberPreparedSoFar()) >= 0 && prepareResponse.getContent() == null) {\n acceptCount++;\n }\n }\n return acceptCount;\n}\n"
"public void renderSeries(IPrimitiveRenderer ipr, Plot p, ISeriesRenderingHints isrh) throws ChartException {\n try {\n validateDataSetCount(isrh);\n } catch (ChartException vex) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, vex);\n }\n boolean bRendering3D = isDimension3D();\n SeriesRenderingHints srh = null;\n SeriesRenderingHints3D srh3d = null;\n if (bRendering3D) {\n srh3d = (SeriesRenderingHints3D) isrh;\n } else {\n srh = (SeriesRenderingHints) isrh;\n }\n ChartWithAxes cwa = (ChartWithAxes) getModel();\n logger.log(ILogger.INFORMATION, Messages.getString(\"String_Node_Str\", new Object[] { getClass().getName(), Integer.valueOf(iSeriesIndex + 1), Integer.valueOf(iSeriesCount) }, getRunTimeContext().getULocale()));\n final Bounds boClientArea = isrh.getClientAreaBounds(true);\n final double dSeriesThickness = bRendering3D ? 0 : srh.getSeriesThickness();\n if (cwa.getDimension() == ChartDimension.TWO_DIMENSIONAL_WITH_DEPTH_LITERAL) {\n boClientArea.delta(-dSeriesThickness, dSeriesThickness, 0, 0);\n }\n LineSeries ls = (LineSeries) getSeries();\n if (!ls.isVisible()) {\n restoreClipping(ipr);\n return;\n }\n ChartDimension cd = cwa.getDimension();\n final AbstractScriptHandler<?> sh = getRunTimeContext().getScriptHandler();\n DataPointHints[] dpha = isrh.getDataPoints();\n validateNullDatapoint(dpha);\n double fX = 0, fY = 0, fZ = 0, fWidth = 0, fWidthZ = 0, fHeight = 0;\n Location lo = null;\n Location3D lo3d = null;\n boolean isAreaSeries = (getSeries() instanceof AreaSeries && !(getSeries() instanceof DifferenceSeries));\n boolean bShowAsTape = (cd.getValue() == ChartDimension.THREE_DIMENSIONAL) || (isAreaSeries && cd.getValue() == ChartDimension.TWO_DIMENSIONAL_WITH_DEPTH);\n if (bShowAsTape) {\n bShowAsTape = validateShowAsTape();\n }\n AxisSubUnit au;\n Axis ax = getAxis();\n double dValue, dEnd;\n StackedSeriesLookup ssl = null;\n if (!bRendering3D) {\n ssl = srh.getStackedSeriesLookup();\n }\n LineAttributes lia = ls.getLineAttributes();\n double[] faX = new double[dpha.length];\n double[] faY = new double[dpha.length];\n double[] faZ = new double[dpha.length];\n SeriesDefinition sd = getSeriesDefinition();\n final EList<Fill> elPalette = sd.getSeriesPalette().getEntries();\n if (elPalette.isEmpty()) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, \"String_Node_Str\", new Object[] { ls }, Messages.getResourceBundle(getRunTimeContext().getULocale()));\n }\n final boolean bPaletteByCategory = isPaletteByCategory();\n if (bPaletteByCategory && ls.eContainer() instanceof SeriesDefinition) {\n sd = (SeriesDefinition) ls.eContainer();\n }\n int iThisSeriesIndex = sd.getRunTimeSeries().indexOf(ls);\n if (iThisSeriesIndex < 0) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, \"String_Node_Str\", new Object[] { ls, sd }, Messages.getResourceBundle(getRunTimeContext().getULocale()));\n }\n Marker m = null;\n if (ls.getMarkers().size() > 0) {\n m = ls.getMarkers().get(iThisSeriesIndex % ls.getMarkers().size());\n }\n Fill fPaletteEntry = null;\n if (!bPaletteByCategory) {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, iThisSeriesIndex);\n } else if (iSeriesIndex > 0) {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, iSeriesIndex - 1);\n }\n updateTranslucency(fPaletteEntry, ls);\n double dTapeWidth = -1;\n double dUnitSpacingZ = 0;\n for (int i = 0; i < dpha.length; i++) {\n if (bRendering3D) {\n lo3d = dpha[i].getLocation3D();\n if (ChartUtil.mathEqual(dTapeWidth, -1)) {\n final double dUnitSpacing = (!cwa.isSetUnitSpacing()) ? 50 : cwa.getUnitSpacing();\n dTapeWidth = dpha[i].getSize2D().getHeight() * (100 - dUnitSpacing) / 100;\n dUnitSpacingZ = dpha[i].getSize2D().getHeight() * dUnitSpacing / 200;\n }\n } else {\n lo = dpha[i].getLocation();\n }\n if (cwa.isTransposed()) {\n if (srh.isCategoryScale()) {\n fHeight = dpha[i].getSize();\n }\n fY = (lo.getY() + fHeight / 2.0);\n faY[i] = fY;\n if (ls.isStacked() || ax.isPercent()) {\n au = ssl.getUnit(ls, i);\n dValue = isNaN(dpha[i].getOrthogonalValue()) ? 0 : ((Double) dpha[i].getOrthogonalValue()).doubleValue();\n dEnd = computeStackPosition(au, dValue, ax);\n try {\n faX[i] = Math.floor(srh.getLocationOnOrthogonal(new Double(dEnd)));\n dpha[i].setStackOrthogonalValue(new Double(dEnd));\n if (faX[i] < srh.getPlotBaseLocation()) {\n faX[i] = srh.getPlotBaseLocation();\n }\n au.setLastPosition(dValue, faX[i], 0);\n } catch (Exception ex) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, ex);\n }\n } else {\n faX[i] = lo.getX();\n }\n } else {\n if (bRendering3D) {\n fWidth = dpha[i].getSize2D().getWidth();\n fWidthZ = dpha[i].getSize2D().getHeight();\n fX = lo3d.getX() + fWidth / 2;\n fZ = lo3d.getZ() + fWidthZ - dUnitSpacingZ;\n faX[i] = fX;\n faZ[i] = fZ;\n } else {\n if (srh.isCategoryScale()) {\n fWidth = dpha[i].getSize();\n }\n fX = (lo.getX() + fWidth / 2.0);\n faX[i] = fX;\n }\n if (ls.isStacked() || ax.isPercent()) {\n if (bRendering3D) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.COMPUTATION, \"String_Node_Str\", Messages.getResourceBundle(getRunTimeContext().getULocale()));\n }\n au = ssl.getUnit(ls, i);\n dValue = isNaN(dpha[i].getOrthogonalValue()) ? 0 : ((Double) dpha[i].getOrthogonalValue()).doubleValue();\n dEnd = computeStackPosition(au, dValue, ax);\n try {\n faY[i] = Math.floor(srh.getLocationOnOrthogonal(new Double(dEnd)));\n dpha[i].setStackOrthogonalValue(new Double(dEnd));\n au.setLastPosition(dValue, faY[i], 0);\n } catch (Exception ex) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, ex);\n }\n } else {\n if (bRendering3D) {\n faY[i] = lo3d.getY();\n } else {\n faY[i] = lo.getY();\n }\n }\n if (bRendering3D) {\n double plotBaseLocation = srh3d.getPlotBaseLocation();\n if (faY[i] < plotBaseLocation) {\n faY[i] = plotBaseLocation;\n }\n if (faY[i] > plotBaseLocation + srh3d.getPlotHeight()) {\n faY[i] = plotBaseLocation + srh3d.getPlotHeight();\n }\n }\n }\n }\n if (!bRendering3D) {\n handleOutsideDataPoints(ipr, srh, faX, faY, bShowAsTape);\n }\n if (ls.isCurve()) {\n renderAsCurve(ipr, ls.getLineAttributes(), bRendering3D ? (ISeriesRenderingHints) srh3d : srh, bRendering3D ? goFactory.createLocation3Ds(faX, faY, faZ) : goFactory.createLocations(faX, faY), bShowAsTape, dTapeWidth, fPaletteEntry, ls.isPaletteLineColor());\n renderShadowAsCurve(ipr, lia, bRendering3D ? (ISeriesRenderingHints) srh3d : srh, bRendering3D ? goFactory.createLocation3Ds(faX, faY, faZ) : goFactory.createLocations(faX, faY), bShowAsTape, dTapeWidth);\n if (m != null) {\n for (int i = 0; i < dpha.length; i++) {\n if (dpha[i].isOutside()) {\n continue;\n }\n if (bPaletteByCategory) {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, i);\n } else {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, iThisSeriesIndex);\n }\n updateTranslucency(fPaletteEntry, ls);\n ScriptHandler.callFunction(sh, ScriptHandler.BEFORE_DRAW_ELEMENT, dpha[i], fPaletteEntry);\n ScriptHandler.callFunction(sh, ScriptHandler.BEFORE_DRAW_DATA_POINT, dpha[i], fPaletteEntry, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.BEFORE_DRAW_ELEMENT, dpha[i]);\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.BEFORE_DRAW_DATA_POINT, dpha[i]);\n renderMarker(ls, ipr, m, bRendering3D ? goFactory.createLocation3D(faX[i], faY[i], faZ[i]) : goFactory.createLocation(faX[i], faY[i]), ls.getLineAttributes(), fPaletteEntry, dpha[i], null, true, true);\n ScriptHandler.callFunction(sh, ScriptHandler.AFTER_DRAW_ELEMENT, dpha[i], fPaletteEntry);\n ScriptHandler.callFunction(sh, ScriptHandler.AFTER_DRAW_DATA_POINT, dpha[i], fPaletteEntry, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.AFTER_DRAW_ELEMENT, dpha[i]);\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.AFTER_DRAW_DATA_POINT, dpha[i]);\n }\n }\n } else {\n renderShadow(ipr, p, lia, bRendering3D ? goFactory.createLocation3Ds(faX, faY, faZ) : goFactory.createLocations(faX, faY), bShowAsTape, dpha);\n renderDataPoints(ipr, p, bRendering3D ? (ISeriesRenderingHints) srh3d : srh, dpha, lia, bRendering3D ? goFactory.createLocation3Ds(faX, faY, faZ) : goFactory.createLocations(faX, faY), bShowAsTape, dTapeWidth, fPaletteEntry, ls.isPaletteLineColor());\n if (m != null) {\n for (int i = 0; i < dpha.length; i++) {\n if (bPaletteByCategory) {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, i);\n } else {\n fPaletteEntry = FillUtil.getPaletteFill(elPalette, iThisSeriesIndex);\n }\n updateTranslucency(fPaletteEntry, ls);\n ScriptHandler.callFunction(sh, ScriptHandler.BEFORE_DRAW_ELEMENT, dpha[i], fPaletteEntry);\n ScriptHandler.callFunction(sh, ScriptHandler.BEFORE_DRAW_DATA_POINT, dpha[i], fPaletteEntry, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.BEFORE_DRAW_ELEMENT, dpha[i]);\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.BEFORE_DRAW_DATA_POINT, dpha[i]);\n renderMarker(ls, ipr, m, bRendering3D ? goFactory.createLocation3D(faX[i], faY[i], faZ[i]) : goFactory.createLocation(faX[i], faY[i]), ls.getLineAttributes(), fPaletteEntry, dpha[i], null, true, true);\n ScriptHandler.callFunction(sh, ScriptHandler.AFTER_DRAW_ELEMENT, dpha[i], fPaletteEntry);\n ScriptHandler.callFunction(sh, ScriptHandler.AFTER_DRAW_DATA_POINT, dpha[i], fPaletteEntry, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.AFTER_DRAW_ELEMENT, dpha[i]);\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.AFTER_DRAW_DATA_POINT, dpha[i]);\n }\n }\n }\n Label laDataPoint = null;\n Position pDataPoint = null;\n Location loDataPoint = null;\n Location3D loDataPoint3d = null;\n try {\n if (bRendering3D) {\n laDataPoint = srh3d.getLabelAttributes(ls);\n if (laDataPoint.isVisible()) {\n pDataPoint = srh3d.getLabelPosition(ls);\n loDataPoint3d = goFactory.createLocation3D(0, 0, 0);\n }\n } else {\n laDataPoint = srh.getLabelAttributes(ls);\n if (laDataPoint.isVisible()) {\n pDataPoint = srh.getLabelPosition(ls);\n loDataPoint = goFactory.createLocation(0, 0);\n }\n }\n } catch (Exception ex) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, ex);\n }\n if (laDataPoint.isVisible()) {\n final double dSize = m == null ? 0 : m.getSize();\n for (int i = 0; i < dpha.length; i++) {\n if (isNaN(dpha[i].getOrthogonalValue()) || dpha[i].isOutside()) {\n continue;\n }\n laDataPoint = bRendering3D ? srh3d.getLabelAttributes(ls) : srh.getLabelAttributes(ls);\n laDataPoint.getCaption().setValue(dpha[i].getDisplayValue());\n ScriptHandler.callFunction(sh, ScriptHandler.BEFORE_DRAW_DATA_POINT_LABEL, dpha[i], laDataPoint, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.BEFORE_DRAW_DATA_POINT_LABEL, laDataPoint);\n if (laDataPoint.isVisible()) {\n if (bRendering3D) {\n switch(pDataPoint.getValue()) {\n case Position.ABOVE:\n loDataPoint3d.set(faX[i], faY[i] + dSize + p.getVerticalSpacing(), faZ[i] + 1);\n break;\n case Position.BELOW:\n loDataPoint3d.set(faX[i], faY[i] - dSize - p.getVerticalSpacing(), faZ[i] + 1);\n break;\n case Position.LEFT:\n loDataPoint3d.set(faX[i] - dSize - p.getHorizontalSpacing(), faY[i], faZ[i] + 1);\n break;\n case Position.RIGHT:\n loDataPoint3d.set(faX[i] + dSize + p.getHorizontalSpacing(), faY[i], faZ[i] + 1);\n break;\n default:\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, \"String_Node_Str\", new Object[] { pDataPoint.getName() }, Messages.getResourceBundle(getRunTimeContext().getULocale()));\n }\n final Text3DRenderEvent tre3d = ((EventObjectCache) ipr).getEventObject(WrappedStructureSource.createSeriesDataPoint(ls, dpha[i]), Text3DRenderEvent.class);\n tre3d.setAction(TextRenderEvent.RENDER_TEXT_AT_LOCATION);\n tre3d.setLabel(laDataPoint);\n tre3d.setTextPosition(Methods.getLabelPosition(pDataPoint));\n tre3d.setLocation3D(loDataPoint3d);\n getDeferredCache().addLabel(tre3d);\n } else {\n switch(pDataPoint.getValue()) {\n case Position.ABOVE:\n loDataPoint.set(faX[i], faY[i] - dSize - p.getVerticalSpacing());\n break;\n case Position.BELOW:\n loDataPoint.set(faX[i], faY[i] + dSize + p.getVerticalSpacing());\n break;\n case Position.LEFT:\n loDataPoint.set(faX[i] - dSize - p.getHorizontalSpacing(), faY[i]);\n break;\n case Position.RIGHT:\n loDataPoint.set(faX[i] + dSize + p.getHorizontalSpacing(), faY[i]);\n break;\n default:\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, \"String_Node_Str\", new Object[] { pDataPoint.getName() }, Messages.getResourceBundle(getRunTimeContext().getULocale()));\n }\n renderLabel(WrappedStructureSource.createSeriesDataPoint(ls, dpha[i]), TextRenderEvent.RENDER_TEXT_AT_LOCATION, laDataPoint, pDataPoint, loDataPoint, null);\n }\n }\n ScriptHandler.callFunction(sh, ScriptHandler.AFTER_DRAW_DATA_POINT_LABEL, dpha[i], laDataPoint, getRunTimeContext().getScriptContext());\n getRunTimeContext().notifyStructureChange(IStructureDefinitionListener.AFTER_DRAW_DATA_POINT_LABEL, laDataPoint);\n }\n }\n if (!bRendering3D && getSeries().getCurveFitting() != null) {\n Location[] larray = new Location[faX.length];\n for (int i = 0; i < larray.length; i++) {\n larray[i] = goFactory.createLocation(faX[i], faY[i]);\n }\n larray = filterNull(larray, isrh.getDataPoints());\n renderFittingCurve(ipr, larray, getSeries().getCurveFitting(), false, true);\n }\n if (!bRendering3D) {\n restoreClipping(ipr);\n }\n}\n"
"public void enforce(HttpRequest request, HttpResponder responder) throws Exception {\n Iterator<MethodArgument> arguments = parseArguments(request);\n EntityId entityId = deserializeNext(arguments);\n Principal principal = deserializeNext(arguments);\n Action action = deserializeNext(arguments);\n LOG.debug(\"String_Node_Str\", action, entityId, principal);\n authorizationEnforcer.enforce(entityId, principal, action);\n responder.sendStatus(HttpResponseStatus.OK);\n}\n"
"public void initialize(AbstractSession session) throws DescriptorException {\n super.initialize(session);\n if (this.fieldToClassMappings.size() == 0) {\n this.convertClassNamesToClasses(((XMLConversionManager) session.getDatasourcePlatform().getConversionManager()).getLoader());\n }\n Iterator<XMLMapping> mappings = getChoiceElementMappings().values().iterator();\n while (mappings.hasNext()) {\n DatabaseMapping nextMapping = (DatabaseMapping) mappings.next();\n nextMapping.setDescriptor(getDescriptor());\n nextMapping.setAttributeAccessor(this.getAttributeAccessor());\n nextMapping.setAttributeName(this.getAttributeName());\n Converter converter = null;\n if (fieldsToConverters != null) {\n converter = fieldsToConverters.get(next);\n }\n if (next.getLastXPathFragment().nameIsText()) {\n XMLCompositeDirectCollectionMapping xmlMapping = new XMLCompositeDirectCollectionMapping();\n xmlMapping.setAttributeName(this.getAttributeName());\n xmlMapping.setAttributeAccessor(this.getAttributeAccessor());\n xmlMapping.setAttributeElementClass(getFieldToClassMappings().get(next));\n XMLConversionManager xmlConversionManager = (XMLConversionManager) session.getDatasourcePlatform().getConversionManager();\n QName schemaType = (QName) xmlConversionManager.getDefaultJavaTypes().get(xmlMapping.getAttributeElementClass());\n if (schemaType != null) {\n next.setSchemaType(schemaType);\n }\n xmlMapping.setField(next);\n xmlMapping.setDescriptor(this.getDescriptor());\n xmlMapping.setContainerPolicy(getContainerPolicy());\n if (converter != null) {\n xmlMapping.setValueConverter(converter);\n }\n this.choiceElementMappings.put(next, xmlMapping);\n xmlMapping.initialize(session);\n } else {\n XMLCompositeCollectionMapping xmlMapping = new XMLCompositeCollectionMapping();\n xmlMapping.setAttributeName(this.getAttributeName());\n xmlMapping.setAttributeAccessor(this.getAttributeAccessor());\n Class refClass = getFieldToClassMappings().get(next);\n if (!refClass.equals(ClassConstants.OBJECT)) {\n xmlMapping.setReferenceClass(refClass);\n }\n xmlMapping.setField(next);\n xmlMapping.setDescriptor(this.getDescriptor());\n xmlMapping.setContainerPolicy(getContainerPolicy());\n if (converter != null) {\n xmlMapping.setConverter(converter);\n }\n this.choiceElementMappings.put(next, xmlMapping);\n xmlMapping.initialize(session);\n }\n }\n}\n"
"protected List<MapGetAllCodec.ResponseParameters> getAllInternal(Map<Integer, List<Data>> pIdToKeyData, Map<K, V> result) {\n Map<Data, Boolean> markers = EMPTY_MAP;\n List<MapGetAllCodec.ResponseParameters> responses;\n try {\n for (Entry<Integer, List<Data>> partitionKeyEntry : pIdToKeyData.entrySet()) {\n List<Data> keyList = partitionKeyEntry.getValue();\n Iterator<Data> iterator = keyList.iterator();\n while (iterator.hasNext()) {\n Data key = iterator.next();\n Object cached = nearCache.get(key);\n if (cached != null && NULL_OBJECT != cached) {\n result.put((K) toObject(key), (V) cached);\n iterator.remove();\n } else if (invalidateOnChange) {\n if (markers == EMPTY_MAP) {\n markers = new HashMap<Data, Boolean>();\n }\n markers.put(key, keyStateMarker.tryMark(key));\n }\n markers.put(key, keyStateMarker.tryMark(key));\n }\n }\n }\n List<MapGetAllCodec.ResponseParameters> responses = super.getAllInternal(pIdToKeyData, result);\n for (MapGetAllCodec.ResponseParameters resultParameters : responses) {\n for (Entry<Data, Data> entry : resultParameters.response) {\n Data key = entry.getKey();\n Data value = entry.getValue();\n Boolean marked = markers.get(key);\n if ((null != marked && marked)) {\n tryToPutNearCache(key, value);\n } else if (!invalidateOnChange) {\n nearCache.put(key, value);\n }\n }\n }\n return responses;\n}\n"
"public void createTable(DataAccess data) throws DatabaseWriteException {\n Connection conn = pool.getConnectionFromPool();\n PreparedStatement ps = null;\n try {\n StringBuilder fields = new StringBuilder();\n HashMap<Column, Object> columns = data.toDatabaseEntryList();\n Iterator<Column> it = columns.keySet().iterator();\n String primary = null;\n Column column;\n while (it.hasNext()) {\n column = it.next();\n fields.append(\"String_Node_Str\").append(column.columnName()).append(\"String_Node_Str\");\n fields.append(this.getDataTypeSyntax(column.dataType()));\n if (column.autoIncrement()) {\n fields.append(\"String_Node_Str\");\n }\n if (column.columnType().equals(Column.ColumnType.PRIMARY)) {\n primary = column.columnName();\n }\n if (it.hasNext()) {\n fields.append(\"String_Node_Str\");\n }\n }\n if (primary != null) {\n fields.append(\"String_Node_Str\").append(primary).append(\"String_Node_Str\");\n }\n ps = conn.prepareStatement(\"String_Node_Str\" + data.getName() + \"String_Node_Str\" + fields.toString() + \"String_Node_Str\");\n ps.execute();\n } catch (SQLException ex) {\n throw new DatabaseWriteException(\"String_Node_Str\" + data.getName() + \"String_Node_Str\" + ex.getMessage());\n } catch (DatabaseTableInconsistencyException ex) {\n Canary.logStacktrace(ex.getMessage() + \"String_Node_Str\" + data.getName() + \"String_Node_Str\", ex);\n } finally {\n this.closePS(ps);\n pool.returnConnectionToPool(conn);\n }\n}\n"
"public ILayout createLayout(ContainerArea parent, LayoutContext context, IContent content) {\n switch(content.getContentType()) {\n case IContent.DATA_CONTENT:\n case IContent.LABEL_CONTENT:\n case IContent.TEXT_CONTENT:\n if (PropertyUtil.isInlineElement(content)) {\n DimensionType width = content.getWidth();\n if (width != null) {\n return new BlockTextArea(parent, context, content);\n } else {\n return new InlineTextArea(parent, context, content);\n }\n } else {\n return new BlockTextArea(parent, context, content);\n }\n case IContent.IMAGE_CONTENT:\n return new ImageAreaLayout(parent, context, (IImageContent) content);\n case IContent.AUTOTEXT_CONTENT:\n int type = ((IAutoTextContent) content).getType();\n if (type == IAutoTextContent.TOTAL_PAGE || type == IAutoTextContent.UNFILTERED_TOTAL_PAGE) {\n context.addUnresolvedContent(content);\n return new TemplateAreaLayout(parent, context, content);\n } else {\n if (PropertyUtil.isInlineElement(content)) {\n return new InlineTextArea(parent, context, content);\n } else {\n return new BlockTextArea(parent, context, content);\n }\n }\n default:\n return null;\n }\n}\n"
"private List<GraphSourceItem> generateIf(SourceGeneratorLocalData localData, GraphTargetItem expression, List<GraphTargetItem> onTrueCmds, List<GraphTargetItem> onFalseCmds, boolean ternar) throws CompilationException {\n List<GraphSourceItem> ret = new ArrayList<>();\n List<AVM2Instruction> onTrue;\n List<AVM2Instruction> onFalse = null;\n if (ternar) {\n onTrue = toInsList(onTrueCmds.get(0).toSource(localData, this));\n } else {\n onTrue = generateToInsList(localData, onTrueCmds);\n }\n if (onFalseCmds != null && !onFalseCmds.isEmpty()) {\n if (ternar) {\n onFalse = toInsList(onFalseCmds.get(0).toSource(localData, this));\n } else {\n onFalse = generateToInsList(localData, onFalseCmds);\n }\n }\n AVM2Instruction ajmp = null;\n if (onFalse != null) {\n if (!((!nonempty(onTrue).isEmpty()) && ((onTrue.get(onTrue.size() - 1).definition instanceof ContinueJumpIns) || ((onTrue.get(onTrue.size() - 1).definition instanceof BreakJumpIns))))) {\n ajmp = ins(AVM2Instructions.Jump, 0);\n onTrue.add(ajmp);\n }\n }\n byte[] onTrueBytes = insToBytes(onTrue);\n int onTrueLen = onTrueBytes.length;\n ret.addAll(notCondition(localData, expression, onTrueLen));\n ret.addAll(onTrue);\n if (onFalse != null) {\n byte[] onFalseBytes = insToBytes(onFalse);\n int onFalseLen = onFalseBytes.length;\n if (ajmp != null) {\n ajmp.operands[0] = onFalseLen;\n }\n ret.addAll(onFalse);\n }\n return ret;\n}\n"
"public AvailableStatus requestFileInformation(DownloadLink downloadLink) throws IOException, InterruptedException, PluginException {\n this.setBrowserExclusive();\n br.getHeaders().put(\"String_Node_Str\", \"String_Node_Str\");\n br.getPage(downloadLink.getDownloadURL());\n if (br.containsHTML(\"String_Node_Str\") || br.containsHTML(\"String_Node_Str\") || br.containsHTML(\"String_Node_Str\"))\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n String name = br.getRegex(Pattern.compile(\"String_Node_Str\")).getMatch(0);\n if (name == null)\n name = br.getRegex(Pattern.compile(\"String_Node_Str\")).getMatch(0);\n if (name == null)\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n String md5Hash = br.getRegex(Pattern.compile(\"String_Node_Str\", Pattern.DOTALL)).getMatch(0);\n if (md5Hash == null)\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n String fileSize = br.getRegex(Pattern.compile(\"String_Node_Str\", Pattern.DOTALL)).getMatch(0);\n if (fileSize == null)\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n fileSize = fileSize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n fileSize = fileSize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n fileSize = fileSize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n fileSize = fileSize + \"String_Node_Str\";\n downloadLink.setMD5Hash(md5Hash.trim());\n downloadLink.setName(name.trim());\n downloadLink.setDownloadSize(Regex.getSize(fileSize));\n return AvailableStatus.TRUE;\n}\n"
"public void setNextParticle() throws NameDuplicationException, IllegalActionException {\n Token _result;\n Token processNoiseSample;\n LinkedList newParticle = new LinkedList();\n for (int i = 0; i < _stateSpaceSize; i++) {\n Parameter p = (Parameter) (_updateEquations.get(_stateVariables[i])).getAttribute(_stateVariables[i]);\n if (p != null) {\n p.setExpression(_particleValue.get(i).toString());\n } else {\n p = new Parameter(_updateEquations.get(_stateVariables[i]), _stateVariables[i]);\n p.setExpression(_particleValue.get(i).toString());\n }\n _tokenMap.put(_stateVariables[i], new DoubleToken((double) _particleValue.get(i)));\n Iterator ci = _controlInputs.keySet().iterator();\n while (ci.hasNext()) {\n String controlVarName = (String) ci.next();\n Parameter c = (Parameter) (_updateEquations.get(_stateVariables[i])).getAttribute(controlVarName);\n if (c != null) {\n c.setExpression(_controlInputs.get(controlVarName).toString());\n } else {\n c = new Parameter(_updateEquations.get(_stateVariables[i]), controlVarName);\n c.setExpression(_controlInputs.get(controlVarName).toString());\n }\n _tokenMap.put(controlVarName, new DoubleToken(_controlInputs.get(controlVarName)));\n }\n }\n try {\n _parseTree = _updateTrees.get(\"String_Node_Str\");\n processNoiseSample = _parseTreeEvaluator.evaluateParseTree(_parseTree, _scope);\n } catch (Throwable throwable) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n if (processNoiseSample == null) {\n throw new IllegalActionException(\"String_Node_Str\" + processNoise.getExpression());\n }\n for (int i = 0; i < _stateSpaceSize; i++) {\n try {\n _parseTree = _updateTrees.get(_stateVariables[i]);\n _result = _parseTreeEvaluator.evaluateParseTree(_parseTree, _scope);\n } catch (Throwable throwable) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n if (_result == null) {\n throw new IllegalActionException(\"String_Node_Str\" + _updateEquations.get(_stateVariables[i]).expression.getExpression());\n }\n double _meanEstimate = ((DoubleToken) _result.add(new DoubleToken(0.0))).doubleValue();\n double processNoiseForElement = ((DoubleToken) ((ArrayToken) processNoiseSample).getElement(i)).doubleValue();\n newParticle.add(_meanEstimate + processNoiseForElement);\n }\n this.setValue(newParticle);\n this.assignWeight();\n}\n"
"public Pony importPony() {\n if (this.version == VERSION_COWSAY)\n return this.importCow();\n boolean[] plain = new boolean[9];\n Color[] colours = new Color[256];\n boolean[] format = plain;\n Color background = null, foreground = null;\n for (int i = 0; i < 256; i++) {\n Colour colour = new Colour(i);\n colours[i] = new Color(colour.red, colour.green, colour.blue);\n }\n if (this.palette != null)\n System.arraycopy(this.palette, 0, colours, 0, 16);\n InputStream in = System.in;\n if (this.file != null)\n in = new BufferedInputStream(new FileInputStream(this.file));\n boolean dollar = false;\n boolean escape = false;\n boolean csi = false;\n boolean osi = false;\n int[] buf = new int[256];\n int ptr = 0;\n int dollareql = -1;\n int width = 0;\n int curwidth = 0;\n int height = 1;\n LinkedList<Object> items = new LinkedList<Object>();\n String comment = null;\n String[][] tags = null;\n int tagptr = 0;\n int[] unmetabuf = new int[4];\n int unmetaptr = 0;\n unmetabuf[unmetaptr++] = in.read();\n unmetabuf[unmetaptr++] = in.read();\n unmetabuf[unmetaptr++] = in.read();\n unmetabuf[unmetaptr++] = in.read();\n if ((unmetabuf[0] == '$') && (unmetabuf[1] == '$') && (unmetabuf[2] == '$') && (unmetabuf[3] == '\\n')) {\n unmetaptr = 0;\n byte[] data = new byte[256];\n int d = 0;\n while ((d = in.read()) != -1) {\n if (ptr == data.length)\n System.arraycopy(data, 0, data = new byte[ptr << 1], 0, ptr);\n data[ptr++] = (byte) d;\n if ((ptr >= 5) && (data[ptr - 1] == '\\n') && (data[ptr - 2] == '$') && (data[ptr - 3] == '$') && (data[ptr - 4] == '$') && (data[ptr - 5] == '\\n')) {\n ptr -= 5;\n break;\n }\n if ((ptr == 4) && (data[ptr - 1] == '\\n') && (data[ptr - 2] == '$') && (data[ptr - 3] == '$') && (data[ptr - 4] == '$')) {\n ptr -= 4;\n break;\n }\n }\n if (d == -1)\n throw new RuntimeException(\"String_Node_Str\");\n String[] code = (new String(data, 0, ptr, \"String_Node_Str\")).split(\"String_Node_Str\");\n StringBuilder commentbuf = new StringBuilder();\n for (String line : code) {\n int colon = line.indexOf(':');\n boolean istag = colon > 0;\n String name = null, value = null;\n block: {\n if (istag) {\n istag = false;\n name = line.substring(0, colon);\n value = line.substring(colon + 1);\n char c;\n for (int i = 0, n = name.length(); i < n; i++) if ((c = name.charAt(i)) != ' ')\n if (('A' > c) || (c > 'Z'))\n break block;\n istag = true;\n }\n }\n if (istag) {\n if (tags == null)\n tags = new String[32][];\n else if (tagptr == tags.length)\n System.arraycopy(tags, 0, tags = new String[tagptr << 1][], 0, tagptr);\n tags[tagptr++] = new String[] { name.trim(), value.trim() };\n } else {\n commentbuf.append(line);\n commentbuf.append('\\n');\n }\n }\n ptr = 0;\n comment = commentbuf.toString();\n while ((ptr < comment.length()) && (comment.charAt(ptr) == '\\n')) ptr++;\n if (ptr > 0) {\n comment = comment.substring(ptr);\n ptr = 0;\n }\n if (comment.isEmpty())\n comment = null;\n if ((tags != null) && (tagptr < tags.length))\n System.arraycopy(tags, 0, tags = new String[tagptr], 0, tagptr);\n }\n for (int d = 0, stored = -1, c; ; ) {\n if (unmetaptr > 0) {\n d = unmetabuf[3 - --unmetaptr];\n if (d == -1)\n break;\n } else if ((d = stored) != -1)\n stored = -1;\n else if ((d = in.read()) == -1)\n break;\n if (((c = d) & 0x80) == 0x80) {\n int n = 0;\n while ((c & 0x80) == 0x80) {\n c <<= 1;\n n++;\n }\n c = (c & 255) >> n;\n while (((d = in.read()) & 0xC0) == 0x80) c = (c << 6) | (d & 0x3F);\n stored = d;\n }\n if (dollar)\n if ((d == '\\033') && !escape)\n escape = true;\n else if ((d == '$') && !escape) {\n dollar = false;\n if (dollareql == -1) {\n int[] _name = new int[ptr];\n System.arraycopy(buf, 0, _name, 0, _name.length);\n String name = utf32to16(_name);\n if (name.equals(\"String_Node_Str\")) {\n curwidth++;\n items.add(new Pony.Cell(this.ignorelink ? ' ' : Pony.Cell.NNE_SSW, null, null, plain));\n } else if (name.equals(\"String_Node_Str\")) {\n curwidth++;\n items.add(new Pony.Cell(this.ignorelink ? ' ' : Pony.Cell.NNW_SSE, null, null, plain));\n } else if (name.startsWith(\"String_Node_Str\") == false)\n items.add(new Pony.Recall(name, foreground, background, format));\n else if (this.ignoreballoon == false) {\n String[] parts = (name.substring(\"String_Node_Str\".length()) + \"String_Node_Str\").split(\"String_Node_Str\");\n Integer h = parts[1].isEmpty() ? null : new Integer(parts[1]);\n int justify = Pony.Balloon.NONE;\n if (parts[0].contains(\"String_Node_Str\"))\n justify = Pony.Balloon.LEFT;\n else if (parts[0].contains(\"String_Node_Str\"))\n justify = Pony.Balloon.RIGHT;\n else if (parts[0].contains(\"String_Node_Str\"))\n justify = Pony.Balloon.CENTRE;\n else\n items.add(new Pony.Balloon(null, null, parts[0].isEmpty() ? null : new Integer(parts[0]), h, null, null, Pony.Balloon.NONE));\n if (justify != Pony.Balloon.NONE) {\n parts = parts[0].replace('l', ',').replace('r', ',').replace('c', ',').split(\"String_Node_Str\");\n int part0 = Integer.parseInt(parts[0]), part1 = Integer.parseInt(parts[1]);\n items.add(new Pony.Balloon(new Integer(part0), null, new Integer(part1 - part0 + 1), h, null, null, justify));\n }\n }\n } else {\n int[] name = new int[dollareql];\n System.arraycopy(buf, 0, name, 0, name.length);\n int[] value = new int[ptr - dollareql - 1];\n System.arraycopy(buf, dollareql + 1, value, 0, value.length);\n items.add(new Pony.Recall(utf32to16(name), utf32to16(value)));\n }\n ptr = 0;\n dollareql = -1;\n } else {\n escape = false;\n if (ptr == buf.length)\n System.arraycopy(buf, 0, buf = new int[ptr << 1], 0, ptr);\n if ((dollareql == -1) && (d == '='))\n dollareql = ptr;\n buf[ptr++] = d;\n }\n else if (escape)\n if (osi)\n if (ptr > 0) {\n buf[ptr++ - 1] = d;\n if (ptr == 8) {\n ptr = 0;\n osi = escape = false;\n int index = (buf[0] < 'A') ? (buf[0] & 15) : ((buf[0] ^ '@') + 9);\n int red = (buf[1] < 'A') ? (buf[1] & 15) : ((buf[1] ^ '@') + 9);\n red = (red << 4) | ((buf[2] < 'A') ? (buf[2] & 15) : ((buf[2] ^ '@') + 9));\n int green = (buf[3] < 'A') ? (buf[3] & 15) : ((buf[3] ^ '@') + 9);\n green = (green << 4) | ((buf[4] < 'A') ? (buf[4] & 15) : ((buf[4] ^ '@') + 9));\n int blue = (buf[5] < 'A') ? (buf[5] & 15) : ((buf[5] ^ '@') + 9);\n blue = (blue << 4) | ((buf[6] < 'A') ? (buf[6] & 15) : ((buf[6] ^ '@') + 9));\n colours[index] = new Color(red, green, blue);\n }\n } else if (ptr < 0) {\n if (~ptr == buf.length)\n System.arraycopy(buf, 0, buf = new int[~ptr << 1], 0, ~ptr);\n if (d == '\\\\') {\n ptr = ~ptr;\n ptr--;\n if ((ptr > 8) && (buf[ptr] == '\\033') && (buf[0] == ';')) {\n int[] _code = new int[ptr - 1];\n System.arraycopy(buf, 1, _code, 0, ptr - 1);\n String[] code = utf32to16(_code).split(\"String_Node_Str\");\n if (code.length == 2) {\n int index = Integer.parseInt(code[0]);\n code = code[1].split(\"String_Node_Str\");\n if ((code.length == 3) && (code[0].startsWith(\"String_Node_Str\"))) {\n code[0] = code[0].substring(4);\n int red = Integer.parseInt(code[0], 16);\n int green = Integer.parseInt(code[1], 16);\n int blue = Integer.parseInt(code[2], 16);\n colours[index] = new Color(red, green, blue);\n }\n }\n }\n ptr = 0;\n osi = escape = false;\n } else {\n buf[~ptr] = d;\n ptr--;\n }\n } else if (d == 'P')\n ptr = 1;\n else if (d == '4')\n ptr = ~0;\n else {\n osi = escape = false;\n items.add(new Pony.Cell('\\033', foreground, background, format));\n items.add(new Pony.Cell(']', foreground, background, format));\n items.add(new Pony.Cell(d, foreground, background, format));\n }\n else if (csi) {\n if (ptr == buf.length)\n System.arraycopy(buf, 0, buf = new int[ptr << 1], 0, ptr);\n buf[ptr++] = d;\n if ((('a' <= d) && (d <= 'z')) || (('A' <= d) && (d <= 'Z')) || (d == '~')) {\n csi = escape = false;\n ptr--;\n if (d == 'm') {\n int[] _code = new int[ptr];\n System.arraycopy(buf, 0, _code, 0, ptr);\n String[] code = utf32to16(_code).split(\"String_Node_Str\");\n int xterm256 = 0;\n boolean back = false;\n for (String seg : code) {\n int value = Integer.parseInt(seg);\n if (xterm256 == 2) {\n xterm256 = 0;\n if (back)\n background = colours[value];\n else\n foreground = colours[value];\n } else if (value == 0) {\n for (int i = 0; i < 9; i++) format[i] = false;\n background = foreground = null;\n } else if (xterm256 == 1)\n xterm256 = value == 5 ? 2 : 0;\n else if (value < 10)\n format[value - 1] = true;\n else if ((20 < value) && (value < 30))\n format[value - 21] = false;\n else if (value == 39)\n foreground = null;\n else if (value == 49)\n background = null;\n else if (value < 38)\n foreground = colours[value - 30];\n else if (value < 48)\n background = colours[value - 40];\n else if (value == 38)\n xterm256 = 1;\n else if (value == 48)\n xterm256 = 1;\n if (xterm256 == 1)\n back = value == 48;\n }\n }\n ptr = 0;\n }\n } else if (d == '[') {\n csi = true;\n ptr = 0;\n } else if (d == ']')\n osi = true;\n else {\n escape = false;\n items.add(new Pony.Cell('\\033', foreground, background, format));\n items.add(new Pony.Cell(d, foreground, background, format));\n curwidth += 2;\n }\n else if (d == '\\033')\n escape = true;\n else if (d == '$')\n dollar = true;\n else if (d == '\\n') {\n if (width < curwidth)\n width = curwidth;\n curwidth = 0;\n height = 0;\n items.add(null);\n } else {\n boolean combining = false;\n if ((0x0300 <= c) && (c <= 0x036F))\n combining = true;\n if ((0x20D0 <= c) && (c <= 0x20FF))\n combining = true;\n if ((0x1DC0 <= c) && (c <= 0x1DFF))\n combining = true;\n if ((0xFE20 <= c) && (c <= 0xFE2F))\n combining = true;\n if (combining)\n items.add(new Pony.Combining(c, foreground, background, format));\n else {\n curwidth++;\n Color fore = foreground == null ? colours[7] : foreground;\n if (c == '▀')\n items.add(new Pony.Cell(Pony.Cell.PIXELS, fore, background, format));\n else if (c == '▄')\n items.add(new Pony.Cell(Pony.Cell.PIXELS, background, fore, format));\n else if (c == '█')\n items.add(new Pony.Cell(Pony.Cell.PIXELS, fore, fore, format));\n else if (c == ' ')\n items.add(new Pony.Cell(Pony.Cell.PIXELS, background, background, format));\n else\n items.add(new Pony.Cell(c, foreground, background, format));\n }\n }\n }\n if (in != System.in)\n in.close();\n Pony pony = new Pony(height, width, comment, tags);\n int y = 0, x = 0;\n Pony.Meta[] metabuf = new Pony.Meta[256];\n int metaptr = 0;\n for (Object obj : items) if (obj == null) {\n if (metaptr != 0) {\n Pony.Meta[] metacell = new Pony.Meta[metaptr];\n System.arraycopy(metabuf, 0, metacell, 0, metaptr);\n pony.matrix[y][x] = metacell;\n metaptr = 0;\n }\n y++;\n x = 0;\n } else if (obj instanceof Pony.Cell) {\n if (metaptr != 0) {\n Pony.Meta[] metacell = new Pony.Meta[metaptr];\n System.arraycopy(metabuf, 0, metacell, 0, metaptr);\n pony.matrix[y][x] = metacell;\n metaptr = 0;\n }\n Pony.Cell cell = (Pony.Cell) obj;\n pony.matrix[y][x++] = cell;\n } else {\n Pony.Meta meta = (Pony.Meta) obj;\n if (metaptr == metabuf.length)\n System.arraycopy(metabuf, 0, metabuf = new Pony.Meta[metaptr << 1], 0, metaptr);\n metabuf[metaptr++] = meta;\n }\n if (metaptr != 0) {\n Pony.Meta[] metacell = new Pony.Meta[metaptr];\n System.arraycopy(metabuf, 0, metacell, 0, metaptr);\n pony.matrix[y][x] = metacell;\n metaptr = 0;\n }\n return pony;\n}\n"
"public void onQPyExec(View v) {\n if (checkAppInstalledByName(getApplicationContext(), extPlgPlusName)) {\n Toast.makeText(this, \"String_Node_Str\", Toast.LENGTH_SHORT).show();\n Intent intent = new Intent();\n intent.setClassName(extPlgPlusName, \"String_Node_Str\");\n intent.setAction(extPlgPlusName + \"String_Node_Str\");\n Bundle mBundle = new Bundle();\n mBundle.putString(\"String_Node_Str\", \"String_Node_Str\");\n mBundle.putString(\"String_Node_Str\", \"String_Node_Str\");\n mBundle.putString(\"String_Node_Str\", \"String_Node_Str\");\n mBundle.putString(\"String_Node_Str\", \"String_Node_Str\");\n EditText codeTxt = (EditText) findViewById(R.id.edit_text);\n String code = codeTxt.getText().toString();\n mBundle.putString(\"String_Node_Str\", code);\n intent.putExtras(mBundle);\n startActivityForResult(intent, SCRIPT_EXEC_PY);\n } else {\n Toast.makeText(getApplicationContext(), \"String_Node_Str\", Toast.LENGTH_LONG).show();\n try {\n Uri uLink = Uri.parse(\"String_Node_Str\");\n Intent intent = new Intent(Intent.ACTION_VIEW, uLink);\n startActivity(intent);\n } catch (Exception e) {\n Uri uLink = Uri.parse(\"String_Node_Str\");\n Intent intent = new Intent(Intent.ACTION_VIEW, uLink);\n startActivity(intent);\n }\n }\n}\n"
"public static void main(String[] args) {\n SplashScreen.getInstance().post(\"String_Node_Str\" + System.getProperty(\"String_Node_Str\") + \"String_Node_Str\");\n handlePrintUsageRequest(args);\n handleLaunchArguments(args);\n setupLogging();\n try (final TerasologyEngine engine = new TerasologyEngine(createSubsystemList())) {\n Config config = CoreRegistry.get(Config.class);\n if (!writeSaveGamesEnabled) {\n config.getTransients().setWriteSaveGamesEnabled(writeSaveGamesEnabled);\n }\n if (serverPort != null) {\n config.getTransients().setServerPort(Integer.parseInt(serverPort));\n }\n if (isHeadless) {\n engine.subscribeToStateChange(new HeadlessStateChangeListener());\n engine.run(new StateHeadlessSetup());\n } else {\n if (loadLastGame) {\n engine.submitTask(\"String_Node_Str\", new Runnable() {\n public void run() {\n GameManifest gameManifest = getLatestGameManifest();\n if (gameManifest != null) {\n engine.changeState(new StateLoading(gameManifest, NetworkMode.NONE));\n }\n }\n });\n }\n SplashScreen.getInstance().close();\n engine.run(new StateMainMenu());\n }\n } catch (Throwable e) {\n if (!GraphicsEnvironment.isHeadless()) {\n reportException(e);\n }\n } finally {\n SplashScreen.getInstance().close();\n }\n}\n"
"public void actionPerformed(ActionEvent actor) {\n int returnVal = 0;\n player = GameManager.getCurrentPlayer();\n if (actor.getActionCommand().equalsIgnoreCase(BUY)) {\n buyButtonClicked();\n passButton.setText(\"String_Node_Str\");\n passButton.setMnemonic(KeyEvent.VK_D);\n } else if (actor.getActionCommand().equalsIgnoreCase(\"String_Node_Str\")) {\n sellButtonClicked();\n passButton.setText(\"String_Node_Str\");\n passButton.setMnemonic(KeyEvent.VK_D);\n } else if (actor.getActionCommand().equalsIgnoreCase(\"String_Node_Str\")) {\n stockRound.done(gameStatus.getSRPlayer());\n passButton.setText(\"String_Node_Str\");\n passButton.setMnemonic(KeyEvent.VK_P);\n }\n try {\n JMenuItem menuItem = (JMenuItem) actor.getSource();\n if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\"))\n System.exit(0);\n if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\"))\n returnVal = new JFileChooser().showSaveDialog(this);\n if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && menuItem.isSelected())\n GameUILoader.messageWindow.setVisible(true);\n else if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && !menuItem.isSelected())\n GameUILoader.messageWindow.setVisible(false);\n if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && menuItem.isSelected())\n GameUILoader.stockChart.setVisible(true);\n else if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && !menuItem.isSelected())\n GameUILoader.stockChart.setVisible(false);\n if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && menuItem.isSelected())\n orWindow = new ORWindow(null, this);\n else if (menuItem.getText().equalsIgnoreCase(\"String_Node_Str\") && !menuItem.isSelected()) {\n orWindow.dispose();\n orWindow = null;\n }\n } catch (ClassCastException e) {\n }\n LogWindow.addLog();\n pack();\n currentRound = GameManager.getInstance().getCurrentRound();\n if (currentRound instanceof StockRound)\n gameStatus.setSRPlayerTurn(GameManager.getCurrentPlayerIndex());\n else if (currentRound instanceof OperatingRound) {\n gameStatus.setSRPlayerTurn(-1);\n updateStatus();\n }\n}\n"
"public List<Sample> getSamples() {\n List<Sample> samples = this.experiment.getSamples();\n List<Sample> result = new ArrayList<>(samples.size());\n for (Sample sample : samples) {\n result.add(new UnmodifiableSample(sample));\n }\n return Collections.unmodifiableList(result);\n}\n"
"private String getNonceFromResponse(Response response) {\n WWWAuthenticate wwwAuth = (WWWAuthenticate) response.getHeader(SIPHeaderNames.WWW_AUTHENTICATE);\n if (wwwAuth != null)\n return wwwAuth.getNonce();\n ProxyAuthenticate proxyAuth = (ProxyAuthenticate) response.getHeader(SIPHeaderNames.PROXY_AUTHENTICATE);\n return (proxyAuth == null) ? null : proxyAuth.getNonce();\n}\n"
"public void drawAngularGridLines(Graphics2D g2, PolarPlot plot, List<ValueTick> ticks, Rectangle2D dataArea) {\n g2.setFont(plot.getAngleLabelFont());\n g2.setStroke(plot.getAngleGridlineStroke());\n g2.setPaint(plot.getAngleGridlinePaint());\n ValueAxis axis = plot.getAxis();\n double centerValue, outerValue;\n if (axis.isInverted()) {\n outerValue = axis.getLowerBound();\n centerValue = axis.getUpperBound();\n } else {\n outerValue = axis.getUpperBound();\n centerValue = axis.getLowerBound();\n }\n Point center = plot.translateToJava2D(0, centerValue, axis, dataArea);\n for (ValueTick tick : ticks) {\n double tickVal = tick.getValue();\n Point p = plot.translateToJava2D(tickVal, maxRadius, plot.getAxis(), dataArea);\n g2.setPaint(plot.getAngleGridlinePaint());\n g2.drawLine(center.x, center.y, p.x, p.y);\n if (plot.isAngleLabelsVisible()) {\n int x = p.x;\n int y = p.y;\n g2.setPaint(plot.getAngleLabelPaint());\n TextUtilities.drawAlignedString(tick.getText(), g2, x, y, tick.getTextAnchor());\n }\n }\n}\n"
"int extendOriginalSequenceNumber(short ssOrigSeqnum) {\n ExtendedSequenceNumberInterval mostRecentInterval = currentExtendedSequenceNumberInterval;\n if (mostRecentInterval == null) {\n Map.Entry<Integer, ExtendedSequenceNumberInterval> entry = intervals.lastEntry();\n if (entry != null) {\n mostRecentInterval = entry.getValue();\n }\n }\n if (mostRecentInterval == null) {\n return usOrigSeqnum;\n }\n int usOriginalSequenceNumber = ssOrigSeqnum & 0x0000ffff;\n int usHighestSeenSeqnum = mostRecentInterval.extendedMaxOrig & 0x0000ffff;\n if (usOriginalSequenceNumber - usHighestSeenSeqnum > 0) {\n if (System.currentTimeMillis() - mostRecentInterval.lastSeen - RETRANSMISSIONS_FRONTIER_MS < 0) {\n if (usOriginalSequenceNumber - (usHighestSeenSeqnum + MAX_UNSIGNED_SHORT) - MEDIAN_UNSIGNED_SHORT > 0) {\n return ((((usHighestSeenSeqnum & 0xffff0000) >> 4) - 1) << 4) | (usOriginalSequenceNumber & 0x0000ffff);\n } else {\n return (usHighestSeenSeqnum & 0xffff0000) | (usOriginalSequenceNumber & 0x0000ffff);\n }\n } else {\n return ((((usHighestSeenSeqnum & 0xffff0000) >> 4) + 1) << 4) | (usOriginalSequenceNumber & 0x0000ffff);\n }\n } else {\n if (System.currentTimeMillis() - mostRecentInterval.lastSeen - RETRANSMISSIONS_FRONTIER_MS < 0) {\n if ((usHighestSeenSeqnum - usOriginalSequenceNumber) - MEDIAN_UNSIGNED_SHORT > 0) {\n return ((((usHighestSeenSeqnum & 0xffff0000) >> 4) + 1) << 4) | (usOriginalSequenceNumber & 0x0000ffff);\n } else {\n return (usHighestSeenSeqnum & 0xffff0000) | (usOriginalSequenceNumber & 0x0000ffff);\n }\n } else {\n return ((((usHighestSeenSeqnum & 0xffff0000) >> 4) + 1) << 4) | (usOriginalSequenceNumber & 0x0000ffff);\n }\n }\n}\n"
"public void processElement(ProcessContext c) {\n Variant v = c.element();\n List<TableRow> calls = new ArrayList<>();\n for (Call call : v.getCalls()) {\n calls.add(new TableRow().set(\"String_Node_Str\", call.getCallSetName()).set(\"String_Node_Str\", call.getPhaseset()).set(\"String_Node_Str\", call.getGenotype()).set(\"String_Node_Str\", (call.getGenotypeLikelihood() == null) ? new ArrayList<Double>() : call.getGenotypeLikelihood()));\n }\n TableRow row = new TableRow().set(\"String_Node_Str\", v.getId()).set(\"String_Node_Str\", v.getReferenceName()).set(\"String_Node_Str\", v.getStart()).set(\"String_Node_Str\", v.getEnd()).set(\"String_Node_Str\", v.getReferenceBases()).set(\"String_Node_Str\", v.getAlternateBases()).set(\"String_Node_Str\", calls);\n c.output(row);\n}\n"
"public void run() {\n System.out.println(\"String_Node_Str\");\n List<MKAnnotation> photos = loadPhotoSet(\"String_Node_Str\");\n if (photos == null)\n throw new UnsupportedOperationException(\"String_Node_Str\");\n System.out.println(\"String_Node_Str\");\n PhotoMapViewController.this.photos = photos;\n DispatchQueue.getMainQueue().async(new Runnable() {\n public void run() {\n NSArray<?> p = new NSArray<>(PhotoMapViewController.this.photos);\n allAnnotationsMapView.addAnnotations((NSArray<NSObject>) p);\n updateVisibleAnnotations();\n loadingStatus.removeFromSuperviewWithFade();\n }\n });\n}\n"
"public void testAverageGetTimeStat() {\n ICache<Integer, String> cache = createCache();\n CacheStatistics stats = cache.getLocalCacheStatistics();\n final int ENTRY_COUNT = 100;\n for (int i = 0; i < ENTRY_COUNT; i++) {\n cache.put(i, \"String_Node_Str\" + i);\n }\n long start = System.nanoTime();\n for (int i = 0; i < 2 * ENTRY_COUNT; i++) {\n cache.get(i);\n }\n long end = System.nanoTime();\n float avgGetTime = NANOSECONDS.toMicros(end - start);\n assertTrue(stats.getAverageGetTime() > 0);\n assertTrue(stats.getAverageGetTime() < avgGetTime);\n}\n"
"public void onReceiveHangUpFromUser(Integer integer) {\n Log.d(CALL_INTEGRATION, \"String_Node_Str\");\n if (!isCleintReadyAccept) {\n waitingTasksMap.clear();\n finish();\n }\n if (currentFragment instanceof IncomingCallFragment || currentFragment instanceof OutgoingCallFragment) {\n showToastMessage(getString(R.string.user_hang_up_call));\n }\n}\n"
"private void _evalFieldMacro(Entity<?> en, List<MappingInfo> infos) {\n for (MappingInfo info : infos) {\n if (null != info.annPrev) {\n en.addBeforeInsertMacro(__macro(en.getField(info.name), _annToFieldMacroInfo(info.annPrev.els(), info.annPrev.value())));\n }\n if (null != info.annNext && en.addAfterInsertMacro(__macro(en.getField(info.name), _annToFieldMacroInfo(info.annNext.els(), info.annNext.value())))) {\n continue;\n } else if (null != info.annId && info.annId.auto()) {\n if (expert != null && !expert.isSupportAutoIncrement()) {\n log.debug(\"String_Node_Str\");\n }\n en.addAfterInsertMacro(expert.fetchPojoId(en, en.getField(info.name)));\n }\n }\n}\n"
"public void discoverSearchTest() throws Exception {\n getClient().perform(get(\"String_Node_Str\")).andExpect(status().isOk()).andExpect(jsonPath(\"String_Node_Str\", is(\"String_Node_Str\"))).andExpect(jsonPath(\"String_Node_Str\", containsString(\"String_Node_Str\"))).andExpect(jsonPath(\"String_Node_Str\", containsString(\"String_Node_Str\"))).andExpect(jsonPath(\"String_Node_Str\", containsInAnyOrder(SearchFilterMatcher.titleFilter(), SearchFilterMatcher.authorFilter(), SearchFilterMatcher.subjectFilter(), SearchFilterMatcher.dateIssuedFilter(), SearchFilterMatcher.hasContentInOriginalBundleFilter()))).andExpect(jsonPath(\"String_Node_Str\", containsInAnyOrder(SortOptionMatcher.titleSortOption(), SortOptionMatcher.dateIssuedSortOption(), SortOptionMatcher.dateAccessionedSortOption(), SortOptionMatcher.scoreSortOption())));\n}\n"
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n DivisionOfficeManager doManager = new DivisionOfficeManagerSession();\n RequestDispatcher view = request.getRequestDispatcher(\"String_Node_Str\");\n ArrayList<String> buildingName = new ArrayList<String>();\n ArrayList<String> buildingAddress = new ArrayList<String>();\n List<Building> buildings = new ArrayList<Building>();\n try {\n buildings = doManager.getAllBuildings();\n } catch (TransactionException e) {\n e.printStackTrace();\n }\n request.setAttribute(\"String_Node_Str\", buildings);\n view.forward(request, response);\n}\n"
"public Container or(BitmapContainer value2) {\n BitmapContainer value1 = this;\n BitmapContainer answer = new BitmapContainer();\n for (int k = 0; k < answer.bitmap.length; ++k) {\n answer.bitmap[k] = value1.bitmap[k] | value2.bitmap[k];\n answer.cardinality += Long.bitCount(answer.bitmap[k]);\n }\n if (answer.cardinality < 1024)\n return new ArrayContainer(answer);\n return answer;\n}\n"
"public void match(PactRecord value1, PactRecord value2, Collector out) throws Exception {\n keyString = value1.getField(0, keyString);\n keyString.setValue(\"String_Node_Str\" + (Integer.parseInt(keyString.getValue()) + 1));\n value1.setField(0, keyString);\n value1.getField(1, valueString);\n int val1 = Integer.parseInt(valueString.getValue()) + 2;\n value2.getField(1, valueString);\n int val2 = Integer.parseInt(valueString.getValue()) + 1;\n value1.setField(1, new PactInteger(val1 - val2));\n out.collect(value1);\n LOG.debug(\"String_Node_Str\" + keyString.toString() + \"String_Node_Str\" + val1 + \"String_Node_Str\" + \"String_Node_Str\" + keyString.toString() + \"String_Node_Str\" + val2 + \"String_Node_Str\");\n}\n"
"public void testRuntimeException() {\n this.request(\"String_Node_Str\").jsonGet();\n}\n"
"private void initOptions() {\n ConfigurableOption bidiProcessing = new ConfigurableOption(BIDI_PROCESSING);\n bidiProcessing.setDisplayName(getMessage(\"String_Node_Str\"));\n bidiProcessing.setDataType(IConfigurableOption.DataType.BOOLEAN);\n bidiProcessing.setDisplayType(IConfigurableOption.DisplayType.CHECKBOX);\n bidiProcessing.setDefaultValue(Boolean.TRUE);\n bidiProcessing.setToolTip(null);\n bidiProcessing.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption textWrapping = new ConfigurableOption(TEXT_WRAPPING);\n textWrapping.setDisplayName(getMessage(\"String_Node_Str\"));\n textWrapping.setDataType(IConfigurableOption.DataType.BOOLEAN);\n textWrapping.setDisplayType(IConfigurableOption.DisplayType.CHECKBOX);\n textWrapping.setDefaultValue(Boolean.TRUE);\n textWrapping.setToolTip(null);\n textWrapping.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption fontSubstitution = new ConfigurableOption(FONT_SUBSTITUTION);\n fontSubstitution.setDisplayName(getMessage(\"String_Node_Str\"));\n fontSubstitution.setDataType(IConfigurableOption.DataType.BOOLEAN);\n fontSubstitution.setDisplayType(IConfigurableOption.DisplayType.CHECKBOX);\n fontSubstitution.setDefaultValue(Boolean.TRUE);\n fontSubstitution.setToolTip(null);\n fontSubstitution.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption pageOverFlow = new ConfigurableOption(IPDFRenderOption.PAGE_OVERFLOW);\n pageOverFlow.setDisplayName(getMessage(\"String_Node_Str\"));\n pageOverFlow.setDataType(IConfigurableOption.DataType.INTEGER);\n pageOverFlow.setDisplayType(IConfigurableOption.DisplayType.COMBO);\n pageOverFlow.setChoices(new OptionValue[] { new OptionValue(IPDFRenderOption.CLIP_CONTENT, getMessage(\"String_Node_Str\")), new OptionValue(IPDFRenderOption.FIT_TO_PAGE_SIZE, getMessage(\"String_Node_Str\")), new OptionValue(IPDFRenderOption.OUTPUT_TO_MULTIPLE_PAGES, getMessage(\"String_Node_Str\")), new OptionValue(IPDFRenderOption.ENLARGE_PAGE_SIZE, getMessage(\"String_Node_Str\")) });\n pageOverFlow.setDefaultValue(IPDFRenderOption.CLIP_CONTENT);\n pageOverFlow.setToolTip(null);\n pageOverFlow.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption embeddedFont = new ConfigurableOption(EMBEDDED_FONT);\n embeddedFont.setDisplayName(getMessage(\"String_Node_Str\"));\n embeddedFont.setDataType(IConfigurableOption.DataType.BOOLEAN);\n embeddedFont.setDisplayType(IConfigurableOption.DisplayType.CHECKBOX);\n embeddedFont.setDefaultValue(Boolean.TRUE);\n embeddedFont.setToolTip(null);\n embeddedFont.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption chartDpi = new ConfigurableOption(CHART_DPI);\n chartDpi.setDisplayName(getMessage(\"String_Node_Str\"));\n chartDpi.setDataType(IConfigurableOption.DataType.INTEGER);\n chartDpi.setDisplayType(IConfigurableOption.DisplayType.TEXT);\n chartDpi.setDefaultValue(new Integer(192));\n chartDpi.setToolTip(\"String_Node_Str\");\n chartDpi.setDescription(getMessage(\"String_Node_Str\"));\n ConfigurableOption renderChartInSVG = new ConfigurableOption(RENDER_CHART_IN_SVG);\n renderChartInSVG.setDisplayName(getMessage(\"String_Node_Str\"));\n renderChartInSVG.setDataType(IConfigurableOption.DataType.BOOLEAN);\n renderChartInSVG.setDisplayType(IConfigurableOption.DisplayType.CHECKBOX);\n renderChartInSVG.setDefaultValue(Boolean.TRUE);\n renderChartInSVG.setToolTip(null);\n renderChartInSVG.setDescription(getMessage(\"String_Node_Str\"));\n options = new IConfigurableOption[] { bidiProcessing, textWrapping, fontSubstitution, pageOverFlow, embeddedFont, chartDpi, renderChartInSVG };\n}\n"
"public void initialize() throws IllegalActionException {\n InputStream source = null;\n Parameter p;\n p = (Parameter) getAttribute(\"String_Node_Str\");\n _xframesize = ((IntToken) p.getToken()).intValue();\n p = (Parameter) getAttribute(\"String_Node_Str\");\n _yframesize = ((IntToken) p.getToken()).intValue();\n p = (Parameter) getAttribute(\"String_Node_Str\");\n _xpartsize = ((IntToken) p.getToken()).intValue();\n p = (Parameter) getAttribute(\"String_Node_Str\");\n _ypartsize = ((IntToken) p.getToken()).intValue();\n _codewords = new IntToken[_yframesize * _xframesize / _ypartsize / _xpartsize];\n _part = new int[_ypartsize * _xpartsize];\n _partitions = new IntMatrixToken[_yframesize * _xframesize / _ypartsize / _xpartsize];\n p = (Parameter) getAttribute(\"String_Node_Str\");\n String filename = ((StringToken) p.getToken()).stringValue();\n try {\n if (filename != null) {\n if (_baseurl != null) {\n try {\n URL dataurl = new URL(_baseurl, filename);\n System.out.println(\"String_Node_Str\" + dataurl);\n source = dataurl.openStream();\n } catch (MalformedURLException e) {\n System.err.println(e.toString());\n } catch (FileNotFoundException e) {\n System.err.println(\"String_Node_Str\" + \"String_Node_Str\" + e);\n } catch (IOException e) {\n System.err.println(\"String_Node_Str\" + \"String_Node_Str\" + e);\n }\n } else {\n File sourcefile = new File(filename);\n if (!sourcefile.exists() || !sourcefile.isFile())\n throw new IllegalActionException(\"String_Node_Str\" + filename + \"String_Node_Str\");\n if (!sourcefile.canRead())\n throw new IllegalActionException(\"String_Node_Str\" + filename + \"String_Node_Str\");\n source = new FileInputStream(sourcefile);\n }\n }\n int i, j, y, x, size = 1;\n byte[] temp;\n for (i = 0; i < 5; i++) {\n size = size * 2;\n temp = new byte[size];\n for (j = 0; j < 256; j++) {\n _codebook[i][j] = new int[size];\n if (_fullread(source, temp) != size)\n throw new IllegalActionException(\"String_Node_Str\" + \"String_Node_Str\");\n for (x = 0; x < size; x++) _codebook[i][j][x] = temp[x] & 255;\n }\n temp = new byte[65536];\n if (_fullread(source, temp) != 65536)\n throw new IllegalActionException(\"String_Node_Str\" + \"String_Node_Str\");\n }\n } catch (Exception e) {\n throw new IllegalActionException(e.getMessage());\n } finally {\n if (source != null) {\n try {\n source.close();\n } catch (IOException e) {\n }\n }\n }\n}\n"
"private static void setupChestLoot(String category) {\n if (DimletConfiguration.unknownDimletChestLootRarity > 0) {\n ChestGenHooks chest = ChestGenHooks.getInfo(category);\n chest.addItem(new WeightedRandomChestContent(DimletSetup.unknownDimlet, 0, DimletConfiguration.unknownDimletChestLootMinimum, DimletConfiguration.unknownDimletChestLootMaximum, DimletConfiguration.unknownDimletChestLootRarity));\n }\n}\n"
"public void loadPlugins() {\n if (alienInitDirectory == null || alienInitDirectory.isEmpty() || alienPluginsInitPath == null) {\n log.debug(\"String_Node_Str\");\n return;\n }\n if (!Files.exists(alienPluginsInitPath) || !Files.isDirectory(alienPluginsInitPath)) {\n log.warn(\"String_Node_Str\", alienPluginsInitPath.toString());\n return;\n }\n try {\n List<Path> plugins = FileUtil.listFiles(alienPluginsInitPath, \"String_Node_Str\");\n for (Path plugin : plugins) {\n try {\n pluginManager.uploadPlugin(plugin);\n } catch (AlreadyExistException e) {\n log.debug(\"String_Node_Str\", plugin.toString());\n } catch (PluginLoadingException | MissingPlugingDescriptorFileException e) {\n log.error(\"String_Node_Str\", plugin.toString(), e);\n }\n }\n } catch (IOException e) {\n log.error(\"String_Node_Str\", e);\n }\n}\n"
"public static boolean pathFinished(HumanNPC npc) {\n return npc.getHandle().pathFinished();\n}\n"
"public void testAddMethod() throws Exception {\n javaClass.addMethod().setName(\"String_Node_Str\").setReturnTypeVoid().setBody(\"String_Node_Str\").getOrigin();\n List<Method> methods = javaClass.getMethods();\n assertEquals(3, methods.size());\n assertNull(methods.get(2).getReturnType());\n}\n"
"private XPathFragment getXPathFragmentForValue(Object value, MarshalRecord marshalRecord, XMLMarshaller marshaller) {\n if (xmlAnyCollectionMapping.usesXMLRoot() && (value instanceof XMLRoot)) {\n XMLRoot xmlRootValue = (XMLRoot) value;\n XPathFragment xmlRootFragment = new XPathFragment(xmlRootValue.getLocalName(), marshalRecord.getNamespaceSeparator(), marshalRecord.isNamespaceAware());\n xmlRootFragment.setNamespaceURI(xmlRootValue.getNamespaceURI());\n return xmlRootFragment;\n }\n if (value instanceof Node) {\n XPathFragment frag = null;\n Node n = (Node) value;\n if (n.getNodeType() == Node.ELEMENT_NODE) {\n Element elem = (Element) n;\n String local = elem.getLocalName();\n if (local == null) {\n local = elem.getNodeName();\n }\n String prefix = elem.getPrefix();\n if (prefix != null && !prefix.equals(XMLConstants.EMPTY_STRING)) {\n frag = new XPathFragment(prefix + marshalRecord.getNamespaceSeparator() + elem.getLocalName(), marshalRecord.getNamespaceSeparator(), marshalRecord.isNamespaceAware());\n } else {\n frag = new XPathFragment(local, marshalRecord.getNamespaceSeparator(), marshalRecord.isNamespaceAware());\n }\n } else if (n.getNodeType() == Node.ATTRIBUTE_NODE) {\n Attr attr = (Attr) n;\n attr.getLocalName();\n String prefix = attr.getPrefix();\n if (prefix != null && prefix.equals(XMLConstants.EMPTY_STRING)) {\n frag = new XPathFragment(prefix + marshalRecord.getNamespaceSeparator() + attr.getLocalName(), marshalRecord.getNamespaceSeparator(), marshalRecord.isNamespaceAware());\n } else {\n frag = new XPathFragment(attr.getLocalName(), marshalRecord.getNamespaceSeparator(), marshalRecord.isNamespaceAware());\n }\n } else if (n.getNodeType() == Node.TEXT_NODE) {\n return SIMPLE_FRAGMENT;\n }\n return frag;\n }\n AbstractSession childSession = null;\n try {\n childSession = marshaller.getXMLContext().getSession(value);\n } catch (XMLMarshalException e) {\n return SIMPLE_FRAGMENT;\n }\n if (childSession != null) {\n XMLDescriptor descriptor = (XMLDescriptor) childSession.getDescriptor(value);\n String defaultRootElementString = descriptor.getDefaultRootElement();\n if (defaultRootElementString != null) {\n return new XPathFragment(defaultRootElementString);\n }\n }\n return null;\n}\n"
"public final Method[] getReflectiveMethods() {\n if (methods != null)\n return methods;\n Class baseclass = getJavaClass();\n Method[] allmethods = baseclass.getDeclaredMethods();\n int n = allmethods.length;\n methods = new Method[n];\n for (int i = 0; i < n; ++i) {\n Method m = allmethods[i];\n if (m.getDeclaringClass() == baseclass) {\n String mname = m.getName();\n if (mname.startsWith(methodPrefix)) {\n int k = 0;\n for (int j = methodPrefixLen; ; ++j) {\n char c = mname.charAt(j);\n if ('0' <= c && c <= '9')\n k = k * 10 + c - '0';\n else\n break;\n }\n methods[k] = m;\n }\n }\n }\n return methods;\n}\n"
"protected void writeInternal(ObjectDataOutput out) throws IOException {\n super.writeInternal(out);\n int count = data.size();\n out.writeInt(count);\n if (count > 0) {\n long now = Clock.currentTimeMillis();\n for (Map.Entry<String, Map<Data, CacheRecord>> entry : source.entrySet()) {\n Map<Data, CacheRecord> cacheMap = entry.getValue();\n int subCount = cacheMap.size();\n out.writeInt(subCount);\n if (subCount > 0) {\n out.writeUTF(entry.getKey());\n for (Map.Entry<Data, CacheRecord> e : cacheMap.entrySet()) {\n final Data key = e.getKey();\n final CacheRecord record = e.getValue();\n final long expirationTime = record.getExpirationTime();\n if (expirationTime > now) {\n key.writeData(out);\n out.writeObject(record);\n }\n subCount--;\n }\n if (subCount != 0) {\n throw new AssertionError(\"String_Node_Str\" + subCount);\n }\n }\n }\n }\n}\n"
"private int countTokensInText(String text) {\n WhitespaceTokenizer tokenizer = new WhitespaceTokenizer();\n tokenizer.setReader(new StringReader(text));\n int tokens = 0;\n try {\n while (tokenizer.incrementToken()) {\n ++tokens;\n }\n } catch (Exception e) {\n LOGGER.error(\"String_Node_Str\", e);\n } finally {\n IOUtils.closeQuietly(tokenizer);\n }\n return tokens;\n}\n"
"public void onWebSocketMessage(WebSocketMessage message) {\n message.getUsernames().stream().filter(username -> webSocketUserPresenceHandler.isPresent(username)).forEach(username -> {\n log.debug(\"String_Node_Str\", message, username);\n messagingTemplate.convertAndSendToUser(username, \"String_Node_Str\", message);\n });\n}\n"
"public KeySetView<K> keySet() {\n return asset.acquireView(KeySetView.class, context);\n}\n"
"public void show() {\n final Locale locale = I18N.getCurrentLocale();\n String filename = null;\n UIModes uiMode = UIModes.valueOf(Config.getProperty(Config.UI_MODE, \"String_Node_Str\").toUpperCase(Locale.ENGLISH));\n if (Gdx.input.isPeripheralAvailable(Peripheral.MultitouchScreen) && uiMode == UIModes.TWO_BUTTONS) {\n uiMode = UIModes.PIE;\n }\n switch(uiMode) {\n case PIE:\n filename = PIE_FILENAME;\n break;\n case SINGLE_CLICK:\n filename = SINGLE_CLICK_FILENAME;\n break;\n case TWO_BUTTONS:\n filename = TWO_BUTTONS_FILENAME;\n break;\n }\n localeFilename = MessageFormat.format(\"String_Node_Str\", filename, locale.getLanguage());\n if (!EngineAssetManager.getInstance().assetExists(localeFilename))\n localeFilename = MessageFormat.format(\"String_Node_Str\", filename);\n tex = new Texture(EngineAssetManager.getInstance().getResAsset(localeFilename));\n tex.setFilter(TextureFilter.Linear, TextureFilter.Linear);\n Gdx.input.setInputProcessor(inputProcessor);\n}\n"
"private void fillDataStore(String text) {\n dataStore.clear();\n int enIndex = text.indexOf(\"String_Node_Str\");\n int frIndex = text.indexOf(\"String_Node_Str\");\n if (enIndex >= 0 && frIndex >= 0) {\n if (enIndex < frIndex) {\n String enDesc = text.substring(enIndex + 4, frIndex - 1);\n String frDesc = text.substring(frIndex + 4, text.length() - 1);\n dataStore.put(\"String_Node_Str\", enDesc);\n dataStore.put(\"String_Node_Str\", frDesc);\n } else {\n String enDesc = text.substring(enIndex + 4, text.length() - 1);\n String frDesc = text.substring(frIndex + 4, enIndex - 1);\n dataStore.put(\"String_Node_Str\", frDesc);\n dataStore.put(\"String_Node_Str\", enDesc);\n }\n }\n if (!find && !text.equals(\"String_Node_Str\")) {\n dataStore.put(\"String_Node_Str\", text);\n }\n}\n"
"public void decorate(Object element, IDecoration decoration) {\n final INodePO node = (INodePO) element;\n IProblem worstProblem = ProblemFactory.getWorstProblem(node.getProblems());\n if (worstProblem != null) {\n switch(worstProblem.getStatus().getSeverity()) {\n case IStatus.WARNING:\n decoration.addOverlay(IconConstants.WARNING_IMAGE_DESCRIPTOR);\n break;\n case IStatus.ERROR:\n decoration.addOverlay(IconConstants.ERROR_IMAGE_DESCRIPTOR);\n break;\n default:\n break;\n }\n }\n}\n"
"public void clearData() {\n if (_selectedItemIndex < 0) {\n return;\n }\n _items.get(_selectedItemIndex).setSelected(false);\n}\n"
"private static Boolean madeEnough(Generation offspring) {\n GAParameters params = GAParameters.getParams();\n if (GAParameters.getParams().getRecord().getGenNum() == 0) {\n List<Pair<StructureOrgCreator, Integer>> initialOrgCreators = params.getInitialOrgCreators();\n for (Pair<StructureOrgCreator, Integer> i : initialOrgCreators) {\n if (i.getSecond() > 0)\n return false;\n }\n if (GAParameters.getParams().getVerbosity() >= 1)\n System.out.println(\"String_Node_Str\");\n return true;\n } else {\n if (params.getNumCalcsInParallel() != 1)\n return offspring.getNumOrganisms() >= Math.min(params.getMinPopSize(), params.getPopSize());\n else\n return offspring.getNumOrganisms() >= params.getPopSize();\n }\n}\n"
"private void addPrimitiveValueConvertingAsNeeded(Class<?> targetType) {\n Object convertedValue = null;\n if (valueToReturn instanceof Number) {\n convertedValue = convertFromNumber(targetType, (Number) valueToReturn);\n } else if (valueToReturn instanceof Character) {\n convertedValue = convertFromChar(targetType, (Character) valueToReturn);\n }\n if (convertedValue == null) {\n throw newIncompatibleTypesException();\n }\n addReturnValue(convertedValue);\n}\n"
"public void addNewsItem(NewsItem ni, Category cat, int matchCount) {\n if (cat.isLeafCategory()) {\n _cache.removeEntriesForGroups(new String[] { \"String_Node_Str\" + cat.getKey() });\n SQL_NewsItem sni = (SQL_NewsItem) ni;\n if (!sni.inTheDB())\n _log.error(\"String_Node_Str\" + sni + \"String_Node_Str\");\n SQL_NewsIndex idx = sni.getNewsIndex();\n INSERT_INTO_CAT_NEWS_TABLE.execute(new Object[] { cat.getKey(), sni.getKey(), idx.getKey(), idx.getCreationTime() });\n cat.setNumArticles(1 + cat.getNumArticles());\n }\n}\n"
"private void addReplicas(Volume volume, String fileName, int replicaNumber) throws IOException, InterruptedException {\n List<String> osdUUIDs = volume.getSuitableOSDs(userCredentials, fileName, replicaNumber);\n assert (osdUUIDs.size() >= replicaNumber);\n int currentReplicaNumber = volume.listReplicas(userCredentials, fileName).getReplicasCount();\n int repl_flags;\n try {\n String rpAsJSON = volume.getXAttr(userCredentials, \"String_Node_Str\", \"String_Node_Str\");\n Map<String, Object> rp = (Map<String, Object>) JSONParser.parseJSON(new JSONString(rpAsJSON));\n long temp = ((Long) rp.get(\"String_Node_Str\"));\n repl_flags = (int) temp;\n } catch (JSONException e) {\n throw new IOException(e);\n }\n Thread.sleep(16 * 1000);\n for (int i = 0; i < replicaNumber; i++) {\n Replica replica = Replica.newBuilder().setStripingPolicy(defaultStripingPolicy).setReplicationFlags(repl_flags).addOsdUuids(osdUUIDs.get(i)).build();\n volume.addReplica(userCredentials, fileName, replica);\n Thread.sleep(16 * 1000);\n System.out.println(\"String_Node_Str\" + osdUUIDs.get(i));\n }\n assertEquals(currentReplicaNumber + replicaNumber, volume.listReplicas(userCredentials, fileName).getReplicasCount());\n}\n"
"void onEvent() {\n long transactionId = inWire.read(TRANSACTION_ID).int64();\n timestamp = inWire.read(TIME_STAMP).int64();\n channelId = inWire.read(CHANNEL_ID).int16();\n inWire.read(METHOD_NAME).text(methodName);\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeVoid(bytesMap -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2);\n bytesMap.put(reader, reader);\n });\n return;\n }\n try {\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeChunked(transactionId, map -> map.keySet().iterator(), writeElement);\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeChunked(transactionId, map -> map.delegate.values().iterator(), writeElement);\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeChunked(transactionId, map -> map.entrySet().iterator(), writeEntry);\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n putAll(transactionId);\n return;\n }\n outWire.write(() -> \"String_Node_Str\").int64(transactionId);\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeVoid(() -> {\n short channelId1 = inWire.read(ARG_1).int16();\n chronicleHashInstanceBuilder.get().replicatedViaChannel(hub.createChannel(channelId1)).create();\n return null;\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n this.remoteIdentifier = inWire.read(RESULT).int8();\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).int64(b.longSize()));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).bool(b.isEmpty()));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).bool(b.containsKey(toReader(inWire, ARG_1))));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).bool(b.containsKey(toReader(inWire, ARG_1))));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValueUsingDelegate(map -> {\n byte[] key1 = this.toByteArray(inWire, ARG_1);\n return map.get(key1);\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValue(b -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2);\n return b.put(reader, reader);\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValue(b -> b.remove(toReader(inWire, ARG_1)));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeVoid(BytesChronicleMap::clear);\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValue(bytesMap -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2);\n return bytesMap.replace(reader, reader);\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValue(bytesMap -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2, ARG_3);\n return bytesMap.replace(reader, reader);\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n writeValue(bytesMap -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2);\n return bytesMap.putIfAbsent(reader, reader);\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(bytesMap -> {\n final net.openhft.lang.io.Bytes reader = toReader(inWire, ARG_1, ARG_2);\n outWire.write(RESULT).bool(bytesMap.remove(reader, reader));\n });\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).text(b.toString()));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).text(applicationVersion()));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).text(persistedDataVersion()));\n return;\n }\n if (\"String_Node_Str\".contentEquals(methodName)) {\n write(b -> outWire.write(RESULT).int32(b.hashCode()));\n return;\n }\n throw new IllegalStateException(\"String_Node_Str\" + methodName);\n } finally {\n if (EventGroup.IS_DEBUG) {\n long len = outWire.bytes().position() - SIZE_OF_SIZE;\n System.out.println(\"String_Node_Str\" + Bytes.toDebugString(outWire.bytes(), SIZE_OF_SIZE, len));\n }\n }\n}\n"
"public void dispose(final GL gl) {\n super.dispose(gl);\n final GL3 gl3 = gl.getGL3();\n final int[] handles = new int[1];\n handles[0] = vbo;\n gl3.glDeleteBuffers(1, handles, 0);\n if (!this.vaoMap.isEmpty()) {\n try {\n for (GLContext context : this.vaoMap.keySet()) {\n context.makeCurrent();\n handles[0] = this.vaoMap.get(context);\n gl3.glDeleteVertexArrays(1, handles, 0);\n }\n } finally {\n gl.getContext().makeCurrent();\n }\n }\n}\n"
"public int compareTo(ReplazableString other) {\n int n = Math.min(used, other.used);\n int k = 0;\n while (k < n) {\n int c1 = this.buffer[k] & 0xFF;\n int c2 = other.buffer[k] & 0xFF;\n if (c1 != c2) {\n return c1 - c2;\n }\n k++;\n }\n return used - other.used;\n}\n"
"private boolean needsValueFunction(PathExpression expression) {\n JoinNode baseNode = (JoinNode) expression.getBaseNode();\n return !expression.isCollectionKeyPath() && baseNode.getParentTreeNode() != null && baseNode.getParentTreeNode().isMap() && expression.getField() == null;\n}\n"
"public void run() throws IOException {\n FileUtils.mkdir(outputDir.getAbsolutePath());\n final List<File> tests = FileUtils.getFiles(baseDir, includes, excludes);\n if (tests.isEmpty()) {\n logger.warn(\"String_Node_Str\");\n return;\n }\n logger.info(\"String_Node_Str\", threadCount);\n logger.info(\"String_Node_Str\", outputStrategy);\n final ExecutorService executorService = Executors.newFixedThreadPool(threadCount);\n final CompletionService<RunStats> completionService = new ExecutorCompletionService<RunStats>(executorService);\n for (final File test : tests) {\n completionService.submit(new Callable<RunStats>() {\n public RunStats call() {\n logger.info(\"String_Node_Str\", test.getAbsoluteFile().toURI().normalize().getPath());\n try {\n final RunStats runStats = runTest(test);\n if (outputStrategy.contains(OutputStrategy.PER_TEST)) {\n writeRunStats(runStats);\n }\n return runStats;\n } catch (final IOException e) {\n logger.error(e.getMessage(), e);\n return null;\n }\n }\n });\n }\n final List<RunStats> allRunStats = Lists.newLinkedList();\n try {\n for (final File test : tests) {\n try {\n final Future<RunStats> future = completionService.take();\n final RunStats runStats = future.get();\n allRunStats.add(runStats);\n } catch (final Exception e) {\n logger.warn(\"String_Node_Str\", test.getAbsolutePath(), e.getMessage());\n logger.debug(e.getMessage(), e);\n }\n }\n } catch (final Exception e) {\n logger.debug(e.getMessage(), e);\n } finally {\n executorService.shutdown();\n }\n logger.info(\"String_Node_Str\");\n if (outputStrategy.contains(OutputStrategy.TOTAL)) {\n final RunStats totalStats = new RunStats(new File(outputDir, reportName), \"String_Node_Str\");\n for (final RunStats runStats : allRunStats) {\n for (final FileStats fileStats : runStats) {\n totalStats.add(fileStats);\n }\n }\n writeRunStats(totalStats);\n }\n}\n"
"public void updateTick(World world, int x, int y, int z, Random rand) {\n if (!world.isRemote) {\n if (this.isRandomlyRadioactive) {\n AxisAlignedBB bounds = AxisAlignedBB.getBoundingBox(x - this.radius, y - this.radius, z - this.radius, x + this.radius, y + this.radius, z + this.radius);\n List<EntityLivingBase> entitiesNearby = world.getEntitiesWithinAABB(EntityLivingBase.class, bounds);\n for (EntityLivingBase entity : entitiesNearby) {\n PoisonRadiation.INSTANCE.poisonEntity(new Vector3(x, y, z), entity, amplifier);\n }\n }\n if (this.canSpread) {\n for (int i = 0; i < 4; ++i) {\n int newX = x + rand.nextInt(3) - 1;\n int newY = y + rand.nextInt(5) - 3;\n int newZ = z + rand.nextInt(3) - 1;\n int blockID = world.getBlockId(newX, newY, newZ);\n if (rand.nextFloat() > 0.4 && (blockID == Block.tilledField.blockID || blockID == Block.grass.blockID)) {\n world.setBlockMetadataWithNotify(newX, newY, newZ, this.blockID, 2);\n }\n }\n if (rand.nextFloat() > 0.85) {\n world.setBlockMetadataWithNotify(x, y, z, Block.mycelium.blockID, 2);\n }\n }\n }\n}\n"
"private SegmentBody loadSegmentFromCache(Map<SegmentHeader, SegmentBody> headerBodies, SegmentHeader header) {\n SegmentBody body = headerBodies.get(header);\n if (body != null) {\n return body;\n }\n body = cacheMgr.compositeCache.get(header);\n if (body == null) {\n cacheMgr.remove(header);\n return null;\n }\n return body;\n}\n"
"private synchronized void loadPredictions() {\n InputStream in = null;\n try {\n predicted = new HashMap();\n Properties temp = NetUtil.loadProperties(predictURI);\n Iterator iter = temp.keySet().iterator();\n while (iter.hasNext()) {\n String title = (String) iter.next();\n String timestr = temp.getProperty(title);\n try {\n Integer time = new Integer(timestr);\n predicted.put(title, time);\n int age = time.intValue();\n if (age > predictedLength) {\n predictedLength = age;\n }\n }\n }\n } catch (IOException ex) {\n log.debug(\"String_Node_Str\");\n } finally {\n IOUtil.close(in);\n }\n}\n"
"public List<Object> toList() {\n List<Object> list = new ArrayList<Object>();\n list.add(data);\n if (selectedCell != null) {\n list.add(selectedCell);\n }\n return list;\n}\n"
"public void setStatus(String statusText) {\n final Menu menu = systemTrayMenu;\n if (menu instanceof _AppIndicatorTray) {\n ((_AppIndicatorTray) menu).setStatus(statusText);\n } else if (menu instanceof _AppIndicatorNativeTray) {\n ((_AppIndicatorNativeTray) menu).setStatus(statusText);\n } else if (menu instanceof _GtkStatusIconTray) {\n ((_GtkStatusIconTray) menu).setStatus(statusText);\n } else if (menu instanceof _GtkStatusIconNativeTray) {\n ((_GtkStatusIconNativeTray) menu).setStatus(statusText);\n } else if (menu instanceof _AwtTray) {\n ((_AwtTray) menu).setStatus(statusText);\n } else if (menu instanceof _SwingTray) {\n ((_SwingTray) menu).setStatus(statusText);\n }\n}\n"
"public boolean lvlup(boolean ignoreItems) {\n checkForItems();\n if (ignoreItems == true) {\n if (getLevel() == -1 && getExp() != 0)\n setExp(0);\n if (getLevel() == -1) {\n Messaging.sendMessage(player, Language.cantLevel);\n return false;\n } else if (nextLevel(true)) {\n return true;\n }\n Messaging.sendMessage(player, \"String_Node_Str\" + ChatColor.YELLOW + RCConfig.maxLevel + ChatColor.WHITE + \"String_Node_Str\");\n return true;\n } else {\n if (hasExpForLevel(getLevel() + 1)) {\n if (getLevel() == -1) {\n Messaging.sendMessage(player, \"String_Node_Str\" + ChatColor.YELLOW + RCPermissions.getPrimaryGroup(player) + ChatColor.WHITE + \"String_Node_Str\");\n return false;\n }\n if (!nextLevel(false)) {\n Messaging.sendMessage(player, \"String_Node_Str\" + ChatColor.YELLOW + RCConfig.maxLevel + ChatColor.WHITE + \"String_Node_Str\");\n return false;\n }\n return true;\n } else {\n Messaging.sendMessage(player, ChatColor.RED + \"String_Node_Str\");\n Messaging.sendMessage(player, \"String_Node_Str\" + ChatColor.YELLOW + getExp() + ChatColor.WHITE + \"String_Node_Str\" + ChatColor.YELLOW + getExpToNextLevel() + ChatColor.WHITE + \"String_Node_Str\");\n return false;\n }\n }\n}\n"
"private String escapeString(char[] src, int from, int to) {\n int len = 1 + to - from;\n if (has_escape(src, from, to) == false) {\n return src.substring(from, to);\n }\n final StringBuilder buf = new StringBuilder(len);\n for (int i = from; i <= to; i++) {\n char c = src[i];\n if (c == '\\\\') {\n int c2 = src[i + 1];\n switch(c2) {\n case '\\'':\n case '\\\"':\n continue;\n case '\\r':\n if (src[i + 2] == '\\n') {\n i++;\n }\n case '\\n':\n i++;\n continue;\n case '\\\\':\n c = '\\\\';\n ++i;\n break;\n case 'u':\n {\n int thisChar = 0;\n int y, digit;\n for (y = i + 2; y < i + 6 && y < to + 1; y++) {\n digit = Character.digit(src[y], 16);\n if (digit == -1)\n break;\n thisChar = (thisChar << 4) + digit;\n }\n if (y != i + 6 || Character.isDefined((char) thisChar) == false) {\n c = src[++i];\n } else {\n c = (char) thisChar;\n i += 5;\n }\n break;\n }\n default:\n {\n if (PASS_ESCAPES_TO_BACKEND) {\n c = src[++i];\n break;\n }\n switch(c2) {\n case 'b':\n c = '\\b';\n ++i;\n break;\n case 'f':\n c = '\\f';\n ++i;\n break;\n case 'n':\n c = '\\n';\n ++i;\n break;\n case 'r':\n c = '\\r';\n ++i;\n break;\n case 't':\n c = '\\t';\n ++i;\n break;\n case 'v':\n c = 0xb;\n ++i;\n break;\n case 'x':\n {\n int d1, d2;\n if (i + 4 > to || (d1 = Character.digit(src[i + 2], 16)) == -1 || (d2 = Character.digit(src[i + 3], 16)) == -1) {\n ++i;\n c = 'x';\n } else {\n i += 3;\n c = (char) ((d1 << 4) + d2);\n }\n break;\n }\n default:\n c = src[++i];\n break;\n }\n }\n }\n }\n buf.append(c);\n }\n return buf.toString();\n}\n"
"protected void handleIQEvent(IQEvent evt) {\n final IQ iq = evt.getIQ();\n if (iq instanceof RosterPacket) {\n final RosterPacket rosterPacket = (RosterPacket) iq;\n if (rosterPacket.getType() == IQ.Type.SET || rosterPacket.getType() == IQ.Type.RESULT) {\n for (final Iterator i = rosterPacket.getRosterItems(); i.hasNext(); ) {\n final RosterPacket.Item item = (RosterPacket.Item) i.next();\n final RosterPacket.ItemType itemType = item.getItemType();\n boolean remove = false;\n XMPPID newID = createIDFromName(item.getUser());\n final IRosterItem[] items = createRosterEntries(newID, item);\n final IRosterEntry entry = createRosterEntry(newID, item);\n if (itemType == RosterPacket.ItemType.NONE || itemType == RosterPacket.ItemType.REMOVE) {\n removeFromRoster(createIDFromName(item.getUser()));\n remove = true;\n } else {\n remove = false;\n addToRoster(items);\n }\n fireSetRosterEntry(remove, entry);\n }\n }\n } else {\n trace(\"String_Node_Str\");\n }\n}\n"
"private DataType resolveTypeName(String modelName, String typeName) {\n DataType result = resolveTopic(modelName, typeName);\n if (result == null) {\n if (modelName == null || modelName.equals(\"String_Node_Str\")) {\n for (Model model : models.values()) {\n DataType modelResult = model.resolveTypeName(typeName);\n if (modelResult != null) {\n if (result != null) {\n throw new IllegalArgumentException(String.format(\"String_Node_Str\", typeName, ((NamedType) result).getName(), ((NamedType) modelResult).getName()));\n }\n result = modelResult;\n }\n result = modelResult;\n }\n }\n } else {\n result = getModel(modelName).resolveTypeName(typeName);\n }\n return result;\n}\n"
"private void spellCheck(QueryRequest req, QueryResult res) throws IOException {\n ArrayList queryTerms = gatherTerms(req.query);\n SpellcheckParams params = req.spellcheckParams;\n if (params.docScoreCutoff > 0 && maxDocScore > params.docScoreCutoff)\n return;\n if (params.totalDocsCutoff > 0 && totalDocs > params.totalDocsCutoff)\n return;\n ArrayList out = new ArrayList();\n for (int i = 0; i < queryTerms.size(); i++) {\n Term term = (Term) queryTerms.get(i);\n if (params.fields != null && !params.fields.contains(term.field()))\n continue;\n SpellingSuggestion sugg = new SpellingSuggestion();\n sugg.origTerm = term;\n sugg.altWords = spellReader.suggestSimilar(term.text(), req.spellcheckParams.suggestionsPerTerm, indexReader, term.field(), params.termOccurrenceFactor, params.accuracy);\n if (sugg.altWords.length > 0)\n out.add(sugg);\n }\n if (out.size() > 0) {\n res.suggestions = (SpellingSuggestion[]) out.toArray(new SpellingSuggestion[out.size()]);\n }\n}\n"
"public void onSuccess(AVIMTypedMessage message) {\n LogUtils.i();\n loadMessagesWhenInit(adapter.getCount());\n}\n"
"public static byte[] fromList(List<Tag> tags) {\n if (tags == null || tags.isEmpty()) {\n return HConstants.EMPTY_BYTE_ARRAY;\n }\n int length = 0;\n for (Tag tag : tags) {\n length += tag.getValueLength() + Tag.INFRASTRUCTURE_SIZE;\n }\n byte[] b = new byte[length];\n int pos = 0;\n int tlen;\n for (Tag tag : tags) {\n tlen = tag.getValueLength();\n pos = Bytes.putAsShort(b, pos, tlen + Tag.TYPE_LENGTH_SIZE);\n pos = Bytes.putByte(b, pos, tag.getType());\n if (tag.hasArray()) {\n pos = Bytes.putBytes(b, pos, tag.getValueArray(), tag.getValueOffset(), tlen);\n } else {\n ByteBufferUtils.copyFromBufferToArray(b, tag.getValueByteBuffer(), tag.getValueOffset(), pos, tlen);\n pos += tlen;\n }\n }\n return b;\n}\n"
"public Void install(String path, AssetTree assetTree) throws IOException {\n String uri = path + \"String_Node_Str\" + putReturnsNull + \"String_Node_Str\" + removeReturnsNull;\n MapView mapView = assetTree.acquireMap(uri, keyType, valueType);\n if (importFile != null) {\n Wire wire = Wire.fromFile(importFile);\n StringBuilder keyStr = new StringBuilder();\n while (!wire.isEmpty()) {\n Object value = wire.readEventName(keyStr).object(valueType);\n Object key = ObjectUtils.convertTo(keyType, keyStr);\n mapView.put(key, value);\n }\n }\n LOGGER.info(\"String_Node_Str\" + path + \"String_Node_Str\" + mapView.size());\n return null;\n}\n"
"public static ArrayList<edu.ucsb.eucalyptus.msgs.Volume> getVolumeReply(Map<String, AttachedVolume> attachedVolumes, List<Volume> volumes) throws EucalyptusCloudException {\n Multimap<String, Volume> partitionVolumeMap = HashMultimap.create();\n Map<String, StorageVolume> idStorageVolumeMap = Maps.newHashMap();\n for (Volume v : volumes) {\n partitionVolumeMap.put(v.getPartition(), v);\n }\n ArrayList<edu.ucsb.eucalyptus.msgs.Volume> reply = Lists.newArrayList();\n for (String partition : partitionVolumeMap.keySet()) {\n try {\n ServiceConfiguration scConfig = Topology.lookup(Storage.class, Partitions.lookupByName(partition));\n Iterator<String> volumeNames = Iterators.transform(partitionVolumeMap.get(partition).iterator(), new Function<Volume, String>() {\n public String apply(Volume arg0) {\n return arg0.getDisplayName();\n }\n });\n DescribeStorageVolumesType descVols = new DescribeStorageVolumesType(Lists.newArrayList(volumeNames));\n Dispatcher sc = ServiceDispatcher.lookup(scConfig);\n DescribeStorageVolumesResponseType volState = sc.send(descVols);\n for (StorageVolume vol : volState.getVolumeSet()) {\n idStorageVolumeMap.put(vol.getVolumeId(), vol);\n }\n for (Volume v : volumes) {\n if (!partition.equals(v.getPartition()))\n continue;\n String status = null;\n Integer size = 0;\n String actualDeviceName = \"String_Node_Str\";\n if (idStorageVolumeMap.containsKey(v.getDisplayName())) {\n StorageVolume vol = idStorageVolumeMap.get(v.getDisplayName());\n status = vol.getStatus();\n size = Integer.parseInt(vol.getSize());\n actualDeviceName = vol.getActualDeviceName();\n } else {\n v.setState(State.ANNIHILATED);\n }\n if (attachedVolumes.containsKey(v.getDisplayName())) {\n v.setState(State.BUSY);\n } else if (status != null) {\n v.setMappedState(status);\n }\n if (v.getSize() <= 0) {\n v.setSize(new Integer(size));\n }\n if (\"String_Node_Str\".equals(v.getRemoteDevice()) || \"String_Node_Str\".equals(v.getRemoteDevice()) || v.getRemoteDevice() == null) {\n v.setRemoteDevice(actualDeviceName);\n }\n edu.ucsb.eucalyptus.msgs.Volume aVolume = v.morph(new edu.ucsb.eucalyptus.msgs.Volume());\n if (attachedVolumes.containsKey(v.getDisplayName())) {\n aVolume.setStatus(v.mapState());\n aVolume.getAttachmentSet().add(attachedVolumes.get(aVolume.getVolumeId()));\n for (AttachedVolume attachedVolume : aVolume.getAttachmentSet()) {\n if (!attachedVolume.getDevice().startsWith(\"String_Node_Str\")) {\n attachedVolume.setDevice(\"String_Node_Str\" + attachedVolume.getDevice());\n }\n }\n }\n if (\"String_Node_Str\".equals(v.getRemoteDevice()) && !State.FAIL.equals(v.getState())) {\n aVolume.setStatus(\"String_Node_Str\");\n }\n reply.add(aVolume);\n }\n } catch (NoSuchElementException ex) {\n LOG.error(ex, ex);\n } catch (NumberFormatException ex) {\n LOG.error(ex, ex);\n }\n }\n return reply;\n}\n"
"public static IBinding loadBinding(DataInputStream dis) throws IOException, DataException {\n int type = IOUtil.readInt(dis);\n String name = IOUtil.readString(dis);\n String function = IOUtil.readString(dis);\n IBaseExpression expr = ExprUtil.loadBaseExpr(dis);\n IBaseExpression filter = ExprUtil.loadBaseExpr(dis);\n Binding binding = new Binding(name);\n binding.setAggrFunction(function);\n binding.setDataType(type);\n binding.setExpression(expr);\n binding.setFilter(filter);\n int argSize = IOUtil.readInt(dis);\n for (int i = 0; i < argSize; i++) {\n binding.addArgument(ExprUtil.loadBaseExpr(dis));\n }\n int aggrSize = IOUtil.readInt(dis);\n for (int i = 0; i < aggrSize; i++) {\n binding.addAggregateOn(IOUtil.readString(dis));\n }\n if (version >= VersionManager.VERSION_2_6_3_1) {\n boolean hasTimeFunction = IOUtil.readBool(dis);\n if (hasTimeFunction) {\n String timeDimensionName = IOUtil.readString(dis);\n TimeFunction time = new TimeFunction();\n if (timeDimensionName != null) {\n time.setTimeDimension(timeDimensionName);\n Date referenceDate = (Date) IOUtil.readObject(dis);\n time.setReferenceDate(new ReferenceDate(referenceDate));\n boolean containsBasePeriod = IOUtil.readBool(dis);\n if (containsBasePeriod) {\n TimePeriodType periodType = getPeriodType(IOUtil.readString(dis));\n int unit = IOUtil.readInt(dis);\n boolean isCurrent = IOUtil.readBool(dis);\n TimePeriod basedTimePeriod = new TimePeriod(unit, periodType, isCurrent);\n time.setBaseTimePeriod(basedTimePeriod);\n }\n boolean containsRelativePeriod = IOUtil.readBool(dis);\n if (containsRelativePeriod) {\n TimePeriodType periodType = getPeriodType(IOUtil.readString(dis));\n int unit = IOUtil.readInt(dis);\n TimePeriod relativeTimePeriod = new TimePeriod(unit, periodType);\n time.setRelativeTimePeriod(relativeTimePeriod);\n }\n }\n binding.setTimeFunction(time);\n }\n }\n return binding;\n}\n"
"public void printLine(String sproduct, double dprice, double dunits) {\n try {\n m_fiscal.printRecItem(sproduct, roundFiscal(dprice * dunits), (int) (dunits * 1000), taxinfo, roundFiscal(dprice), \"String_Node_Str\");\n } catch (JposException e) {\n }\n}\n"
"private void performZoom(MotionEvent event) {\n if (event.getPointerCount() >= 2) {\n float totalDist = spacing(event);\n if (totalDist > 10f) {\n PointF t = getTrans(mTouchPointCenter.x, mTouchPointCenter.y);\n if (mTouchMode == PINCH_ZOOM) {\n float scale = totalDist / mSavedDist;\n mMatrix.set(mSavedMatrix);\n mMatrix.postScale((mChart.isScaleXEnabled()) ? scale : 1f, (mChart.isScaleYEnabled()) ? scale : 1f, t.x, t.y);\n } else if (mTouchMode == X_ZOOM && mChart.isScaleXEnabled()) {\n float xDist = getXDist(event);\n float scaleX = xDist / mSavedXDist;\n mMatrix.set(mSavedMatrix);\n mMatrix.postScale(scaleX, 1f, t.x, t.y);\n } else if (mTouchMode == Y_ZOOM) {\n float yDist = getYDist(event);\n float scaleY = yDist / mSavedYDist;\n mMatrix.set(mSavedMatrix);\n mMatrix.postScale(1f, scaleY, t.x, t.y);\n }\n }\n }\n}\n"
"private void addConditionalExprBindings(TotalExprBinding result, IConditionalExpression key, List bindings, String groupName) throws EngineException {\n try {\n IConditionalExpression ce = key;\n if (hasAggregationInFilter(key)) {\n result.addNewExpression(ce);\n return;\n }\n if (groupName != null)\n ce.setGroupName(groupName);\n String bindingName = TOTAL_PREFIX + totalColumnSuffix;\n totalColumnSuffix++;\n Binding columnBinding = new Binding(bindingName, ce);\n if (groupName != null) {\n columnBinding.addAggregateOn(groupName);\n }\n List allColumnBindings = new ArrayList();\n allColumnBindings.add(columnBinding);\n result.addColumnBindings(allColumnBindings);\n result.addNewExpression(org.eclipse.birt.core.data.ExpressionUtil.createJSRowExpression(bindingName));\n } catch (DataException e) {\n throw new EngineException(e.getLocalizedMessage());\n }\n}\n"
"public Date generateDateBetween(String minString, String maxString, RandomWrapper rnd) {\n SimpleDateFormat df = new SimpleDateFormat(\"String_Node_Str\");\n Date minDate = null;\n Date maxDate = null;\n try {\n minDate = df.parse(minString);\n maxDate = df.parse(maxString);\n } catch (ParseException e) {\n return new Date(System.currentTimeMillis());\n }\n if (minDate.after(maxDate)) {\n Date tmp = minDate;\n minDate = maxDate;\n maxDate = tmp;\n } else if (minDate.equals(maxDate)) {\n return minDate;\n }\n long min = minDate.getTime();\n long max = maxDate.getTime();\n long number = min + ((long) (rnd.nextDouble() * (max - min)));\n Date newDate = new Date(number);\n return newDate;\n}\n"
"protected void computeResult() {\n MavenProject targetPOM = getTargetPOM();\n IMavenProjectFacade facade = MavenPlugin.getDefault().getMavenProjectManager().getMavenProject(targetPOM.getGroupId(), targetPOM.getArtifactId(), targetPOM.getVersion());\n Model targetModel;\n EditingDomain targetEditingDomain;\n CompoundCommand command = new CompoundCommand();\n CompoundCommand targetCommand;\n if (targetPOM.equals(getProjectHierarchy().getFirst())) {\n targetModel = model;\n } else {\n targetModel = loadTargetModel(facade);\n if (targetModel == null) {\n return;\n }\n }\n LinkedList<Dependency> dependencies = getDependenciesList();\n CompoundCommand command = new CompoundCommand();\n for (Dependency dep : dependencies) {\n Command unset = SetCommand.create(editingDomain, dep, PomPackage.eINSTANCE.getDependency_Version(), SetCommand.UNSET_VALUE);\n command.append(unset);\n }\n DependencyManagement management = targetModel.getDependencyManagement();\n if (management == null) {\n management = PomFactory.eINSTANCE.createDependencyManagement();\n Command createDepManagement = SetCommand.create(editingDomain, targetModel, PomPackage.eINSTANCE.getModel_DependencyManagement(), management);\n command.append(createDepManagement);\n } else {\n for (Dependency depFromTarget : management.getDependencies()) {\n Iterator<Dependency> iter = dependencies.iterator();\n while (iter.hasNext()) {\n Dependency depFromSource = iter.next();\n if (depFromSource.getGroupId().equals(depFromTarget.getGroupId()) && depFromSource.getArtifactId().equals(depFromTarget.getArtifactId())) {\n iter.remove();\n }\n }\n }\n }\n for (Dependency dep : dependencies) {\n Dependency clone = PomFactory.eINSTANCE.createDependency();\n Command addDepCommand = AddCommand.create(editingDomain, management, PomPackage.eINSTANCE.getDependencyManagement_Dependencies(), clone);\n command.append(addDepCommand);\n command.append(createCommand(clone, dep.getGroupId(), PomPackage.eINSTANCE.getDependency_GroupId(), \"String_Node_Str\"));\n command.append(createCommand(clone, dep.getArtifactId(), PomPackage.eINSTANCE.getDependency_ArtifactId(), \"String_Node_Str\"));\n command.append(createCommand(clone, dep.getVersion(), PomPackage.eINSTANCE.getDependency_Version(), \"String_Node_Str\"));\n }\n editingDomain.getCommandStack().execute(command);\n}\n"
"private JavaRDD<Cells> executeInitialStep(LogicalStep logicalStep, JavaRDD<Cells> rdd, String tableName) throws ExecutionException {\n LogicalStep currentStep = logicalStep;\n while (currentStep != null) {\n if (currentStep instanceof Filter) {\n executeFilter((Filter) currentStep, rdd);\n } else if (currentStep instanceof Select) {\n prepareResult((Select) currentStep, rdd);\n } else if (currentStep instanceof UnionStep) {\n UnionStep unionStep = (UnionStep) currentStep;\n if (!executeUnion(unionStep, rdd)) {\n break;\n }\n } else {\n throw new ExecutionException(\"String_Node_Str\" + currentStep.getOperation().toString() + \"String_Node_Str\");\n }\n currentStep = currentStep.getNextStep();\n }\n partialResultsMap.put(tableName, rdd);\n return rdd;\n}\n"