content
stringlengths
40
137k
"public static String htmlAttributeEscape(String text) {\n return htmlEscape(text, true, false);\n}\n"
"public List<Reservation> getReservations() {\n return new ArrayList<Reservation>(reservations.values());\n}\n"
"public static String getTmpDestinationFolder() {\n String tmp = getTmpFolderPath() + \"String_Node_Str\";\n tmp = tmp.replace('\\\\', '/');\n File f = new File(tmp);\n if (!f.exists()) {\n f.mkdir();\n }\n return tmp;\n}\n"
"public void preProcessTree(String filename) {\n TreeReader tr = new TreeReader();\n String ts = \"String_Node_Str\";\n try {\n BufferedReader br = new BufferedReader(new FileReader(filename));\n ts = br.readLine();\n br.close();\n } catch (IOException ioe) {\n }\n tr.setTree(ts);...
"public String generateUniqueNodeName(INode node) {\n String baseName = node.getComponent().getOriginalName();\n return UniqueNodeNameGenerator.generateUniqueNodeName(baseName, uniqueNodeNameList);\n}\n"
"private void createIndicatorParameters(TreeItem indicatorItem, IndicatorUnit indicatorUnit) {\n TreeItem[] items = indicatorItem.getItems();\n if (indicatorItem != null && !indicatorItem.isDisposed()) {\n for (TreeItem treeItem : items) {\n if (DATA_PARAM.equals(treeItem.getData(DATA_PARAM))) {...
"private boolean isCubeMode() {\n return ChartXTabUtil.getBindingCube(itemHandle) != null;\n}\n"
"public Object clone(Workspace ws) throws CloneNotSupportedException {\n try {\n _workspace.getReadAccess();\n NamedObj newObject = (NamedObj) super.clone();\n newObject._attributes = null;\n newObject._workspace = workspace;\n newObject._fullNameVersion = -1;\n Iterator par...
"public void encodeEnd(FacesContext context, UIComponent component) throws IOException {\n if (!component.isRendered()) {\n return;\n }\n InputTextarea inputText = (InputTextarea) component;\n ResponseWriter rw = context.getResponseWriter();\n int span = inputText.getSpan();\n if (span > 0) {\n...
"public void setParent(IElement parent) {\n super.setParent(parent);\n if (parent != null) {\n ((IContent) parent).setHasChildren(true);\n }\n}\n"
"public static boolean findElementsUsingType(ArrayList<Object> objList, String namespace, String localName) {\n if (null == localName) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n for (Iterator<Object> iter = objList.iterator(); iter.hasNext(); ) {\n Object obj = iter.next()...
"public void keyPresses(String sKey) {\n if (sKey.length() > 1) {\n if (mSolved)\n replaceExpression(sKey);\n else\n insertAtSelection(sKey);\n mSolved = false;\n return;\n }\n if (sKey.matches(regexHasInvalidChars))\n throw new IllegalArgumentException(...
"public void cleanup(Emitter<Pair<Integer, GenericData.Record>> emitter) {\n if (lastKey != null && lastValue != null) {\n System.out.println(\"String_Node_Str\" + lastKey);\n System.out.println(\"String_Node_Str\" + lastValue);\n GenericData.Record wrapper = new GenericData.Record(wrapperSchema...
"public void run() {\n list.removeAll(removed);\n newList.stream().forEachOrdered(item -> updateCachedListItem((Listable) item, list));\n dcHandler.writeToFile(repoId, issuesETag, collabsETag, labelsETag, milestonesETag, issueCheckTime, collaborators, labels, milestones, issues);\n}\n"
"private static TLAExpr SubExpr(String sub) {\n TLAExpr expr = new TLAExpr();\n if (sub != null) {\n TLAExpr expr = sub.cloneAndNormalize();\n for (int i = 0; i < expr.tokens.size(); i++) {\n Vector tokenVec = (Vector) expr.tokens.elementAt(i);\n for (int j = 0; j < tokenVec.si...
"protected void keepUnresolvedCells() {\n if (rowCount <= 0) {\n return;\n }\n if (rowHint == null) {\n Row row = rows[rowCount - 1];\n Cell[] cells = rows[rowCount - 1].cells;\n IRowContent rowContent = (IRowContent) row.getContent();\n ITableContent table = rowContent.getTa...
"public Endpoint getAnEndpoint() throws InterruptedException {\n if (settings.getUseQuickConnect() && stale) {\n try {\n synchronized (staleWaitersLock) {\n staleWaiters++;\n staleWaitersLock.notify();\n }\n synchronized (staleLock) {\n ...
"public void verifyTraces(PluginTestVerifier verifier, String expectedMessage) throws Exception {\n ExpectedTrace asyncClientInvocationTrace = event(\"String_Node_Str\", \"String_Node_Str\");\n Method start = TAsyncMethodCall.class.getDeclaredMethod(\"String_Node_Str\", Selector.class);\n ExpectedTrace startTr...
"public void create() {\n if (getSourceCidrList() != null) {\n String guestCidr = _networkService.getNetwork(getNetworkId()).getCidr();\n for (String cidr : getSourceCidrList()) {\n if (!NetUtils.isValidCIDR(cidr)) {\n throw new ServerApiException(ApiErrorCode.PARAM_ERROR, \"S...
"protected void fireEditingStopped() {\n for (CellEditorListener l : editorListeners.toArray(new CellEditorListener[] {})) {\n if (l != null) {\n l.editingStopped(new ChangeEvent(this));\n }\n }\n}\n"
"public void prepare(String command) throws OdaException {\n logger.logp(java.util.logging.Level.FINE, CallStatement.class.getName(), \"String_Node_Str\", \"String_Node_Str\" + command + \"String_Node_Str\");\n try {\n if (command == null) {\n logger.logp(java.util.logging.Level.FINE, CallStatem...
"public void merge(Configuration config) {\n if (config == null) {\n System.out.println(\"String_Node_Str\");\n }\n loadFile();\n if (config.login().isEmpty() && login != null) {\n config.setLogin(login);\n }\n if (config.password().isEmpty() && password != null) {\n config.setPas...
"private synchronized void readObject(java.io.ObjectInputStream s) throws java.io.IOException, ClassNotFoundException {\n s.defaultReadObject();\n init();\n int size = s.readInt();\n if (size > 0) {\n List groupsInfo = (List) s.readObject();\n for (int i = 0; i < size; i++) _groupsInfo.add((in...
"public CheckedListenableFuture<R> dispatch(final ServiceConfiguration serviceConfig) {\n try {\n ServiceEndpoint serviceEndpoint = serviceConfig.lookupEndpoint();\n serviceEndpoint.enqueue(this);\n return this.getResponse();\n } catch (Exception ex1) {\n Future<CheckedListenableFuture...
"public TPaoDaiBase getTurret(boolean getNew) {\n Vector3 position = new Vector3(this);\n if (getNew || this.turret == null || this.turret.isInvalid() || !(new Vector3(this.turret).equals(position.clone().modifyPositionFromSide(this.deployDirection)))) {\n TileEntity tileEntity = position.clone().modifyPos...
"private static Country getCountryMatched(Optional<Country> countryName, Optional<Country> countryCode) {\n if (countryCode.isPresent()) {\n return countryCode.get();\n }\n if (countryName.isPresent()) {\n return countryName.get();\n }\n return null;\n}\n"
"private void computeEdges() {\n for (Iterator it = iterator(); it.hasNext(); ) {\n BasicBlock b = (BasicBlock) it.next();\n if (b.equals(exit()))\n continue;\n if (b.equals(entry())) {\n addNormalEdge(b, getNode(b.getGraphNodeId() + 1));\n continue;\n }\n...
"public static <T extends ImageBase, D extends ImageBase> void doStuff(BufferedImage input, Class<T> imageType, Class<D> derivType) {\n T workImage = ConvertBufferedImage.convertFrom(input, null, imageType);\n AnyImageDerivative<T, D> deriv = UtilScaleSpace.createDerivatives(imageType, FactoryImageGenerator.creat...
"public void testWTD3() throws IOException {\n int[] values = new int[] { 2002, 1, 2, 1, 7 };\n String[] types = new String[] { TimeMember.TIME_LEVEL_TYPE_YEAR, TimeMember.TIME_LEVEL_TYPE_QUARTER, TimeMember.TIME_LEVEL_TYPE_MONTH, TimeMember.TIME_LEVEL_TYPE_WEEK_OF_MONTH, TimeMember.TIME_LEVEL_TYPE_DAY_OF_WEEK };...
"protected void createToolItems(ToolBarManager tbm) {\n final Action nextDiff = new AbstractCompareAction(ResourceBundle.getBundle(BUNDLE_NAME), \"String_Node_Str\") {\n public void run() {\n navigate(true);\n }\n };\n final ActionContributionItem nextDiffContribution = new ActionContr...
"public void check_Create_SQL() {\n SqlManager sqls = new FileSqlManager(PATH);\n Sql sql = sqls.create(\"String_Node_Str\");\n assertTrue(sql.toString().toUpperCase().startsWith(\"String_Node_Str\"));\n}\n"
"private void connectPronounStates() {\n DictionaryItem ben = lexicon.getItemById(\"String_Node_Str\");\n DictionaryItem sen = lexicon.getItemById(\"String_Node_Str\");\n DictionaryItem o = lexicon.getItemById(\"String_Node_Str\");\n DictionaryItem biz = lexicon.getItemById(\"String_Node_Str\");\n Dictio...
"public int read() throws IOException {\n if (currentStream == -1) {\n throw new IOException(\"String_Node_Str\");\n }\n InputStream cur = ((InputStream) streams.elementAt(currentStream));\n int next = cur.read();\n if (next != -1) {\n return next;\n }\n while (next == -1 && currentSt...
"public void startRequest(MRCRequest rq) {\n try {\n Args rqArgs = (Args) rq.getRequestArgs();\n final VolumeManager vMan = master.getVolumeManager();\n final FileAccessManager faMan = master.getFileAccessManager();\n final Path p = new Path(rqArgs.linkPath);\n final VolumeInfo vol...
"public Query rewrite(QueryLanguage ql, String query, String baseuri) throws MalformedQueryException, RepositoryException, RuntimeException {\n QueryParserFactory f = QueryParserRegistry.getInstance().get(ql);\n QueryParser parser = f.getParser();\n ParsedQuery parsed = parser.parseQuery(query, baseuri);\n ...
"private void waitDebugProcessing() {\n while (m_debugServer.debugIsProcessing()) {\n }\n try {\n while (m_debugServer.debugIsProcessing()) {\n }\n Thread.currentThread();\n Thread.sleep(100);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n}\n"
"public int getAllocatedHeight() {\n return height + PropertyUtil.getDimensionValue(style.getProperty(StyleConstants.STYLE_MARGIN_TOP)) + PropertyUtil.getDimensionValue(style.getProperty(StyleConstants.STYLE_MARGIN_BOTTOM));\n}\n"
"public void testgetReplica() throws Exception {\n System.out.println(\"String_Node_Str\");\n makeDB();\n insertData();\n long seqToRequest = 2L;\n RPCResponse<LogEntries> result = client.getReplica(new LSNRange(viewID, seqToRequest, seqToRequest));\n LogEntries les = result.get();\n assertNotNull(...
"private UptimeStats getUptimeAndCpuIdleTime() {\n UptimeStats uptime = new UptimeStats(0d, 0d);\n File f = new File(_uptimeFile);\n try (Scanner scanner = new Scanner(f, \"String_Node_Str\")) {\n String[] stats = scanner.useDelimiter(\"String_Node_Str\").next().split(\"String_Node_Str\");\n upti...
"public void removeEventUpdates(IDroidPlannerApiCallback callback) throws RemoteException {\n if (callback != null) {\n apiCallbacks.remove(callback);\n}\n"
"public void node(Node node, NamespaceResolver namespaceResolver) {\n if (node.getNodeType() == Node.ATTRIBUTE_NODE) {\n Attr attr = (Attr) node;\n String resolverPfx = null;\n if (getNamespaceResolver() != null) {\n resolverPfx = getNamespaceResolver().resolveNamespaceURI(attr.getNam...
"public Triggerable addTriggerable(Triggerable t) {\n int existingIx = triggerables.indexOf(t);\n if (existingIx >= 0) {\n Triggerable existingTriggerable = (Triggerable) triggerables.elementAt(existingIx);\n existingTriggerable.contextRef = existingTriggerable.contextRef.intersect(t.contextRef);\n ...
"private void setupExplodedWar() throws MojoExecutionException {\n getLog().info(\"String_Node_Str\" + hostedWebapp);\n if (copyWebapp && !warSourceDirectory.getAbsolutePath().equals(hostedWebapp.getAbsolutePath())) {\n try {\n copyDirectoryStructureIfModified(warSourceDirectory, hostedWebapp);\...
"public static void setUp() throws WSDLException {\n if (conn == null) {\n try {\n conn = buildConnection();\n } catch (Exception e) {\n e.printStackTrace();\n }\n }\n String ddlCreateProp = System.getProperty(DATABASE_DDL_CREATE_KEY, DEFAULT_DATABASE_DDL_CREATE);\n ...
"public WiresConnector setHeadMagnet(WiresMagnet headMagnet) {\n m_headConnection.setMagnet(headMagnet);\n return this;\n}\n"
"private final void typeCheck(String externs, String js, DiagnosticType... warningKinds) {\n parseAndTypeCheck(externs, js);\n JSError[] warnings = compiler.getWarnings();\n JSError[] errors = compiler.getErrors();\n String errorMessage = \"String_Node_Str\" + \"String_Node_Str\" + Arrays.toString(warningKi...
"public void readEntityFromNBT(NBTTagCompound nbt) {\n super.readEntityFromNBT(nbt);\n ticks = nbt.getByte(\"String_Node_Str\");\n enhancements.deserialize(nbt.getString(\"String_Node_Str\"));\n}\n"
"public void submit(String indexName, Args args, String data) {\n String sendString = \"String_Node_Str\";\n RequestMessage request = new RequestMessage(\"String_Node_Str\");\n request.setContent(data);\n if (indexName != null) {\n sendString = String.format(\"String_Node_Str\", indexName);\n }\n ...
"public String listenStart(final String streamName) {\n try {\n ssaw.api().listenStream(streamName);\n return \"String_Node_Str\".concat(streamName).concat(\"String_Node_Str\");\n } catch (StratioEngineStatusException | StratioAPISecurityException e) {\n throw new StreamingShellException(e);\...
"private void onListDataChange(ListDataEvent event) {\n int type = event.getType();\n if ((type == ListDataEvent.INTERVAL_ADDED || type == ListDataEvent.CONTENTS_CHANGED) && !isIgnoreSortWhenChanged()) {\n doSort(this);\n } else if (type == ListDataEvent.SELECTION_CHANGED) {\n if (_model instance...
"public AGLView createGLView(GLCaleydoCanvas glCanvas, String label, IViewFrustum viewFrustum) {\n return new GLDendrogram(glCanvas, label, viewFrustum, true);\n}\n"
"public void run() {\n SctpSocket sctpSocket = null;\n try {\n sctpSocket = SctpConnection.this.sctpSocket;\n while (sctpSocket != null) {\n if (sctpSocket.accept()) {\n acceptedIncomingConnection = true;\n break;\n }\n Thread.sleep(100)...
"public void onBrowserEvent(Context context, Element parent, HeaderDetails value, NativeEvent event, ValueUpdater<HeaderDetails> valueUpdater) {\n super.onBrowserEvent(context, parent, value, event, valueUpdater);\n Element filterImageElement = getImageElement(parent);\n Element filterImageParentElement = filt...
"public void handleMessage(android.os.Message msg) {\n switch(msg.what) {\n case MSG_ENROLL_RESULT:\n sendEnrollResult((Fingerprint) msg.obj, msg.arg1);\n break;\n case MSG_ACQUIRED:\n sendAcquiredResult((Long) msg.obj, msg.arg1);\n break;\n case MSG_A...
"public boolean apply(Game game, Ability source) {\n TargetPermanent target = (TargetPermanent) source.getTargets().get(0);\n Permanent permanent = game.getPermanent(target.getFirstTarget());\n Player player = game.getPlayer(source.getControllerId());\n if (permanent != null && player != null) {\n in...
"public void showSuggestions(SuggestedWords suggestedWords, CharSequence typedWord) {\n setSuggestions(suggestedWords);\n if (suggestedWords.size() > 0) {\n if (shouldBlockAutoCorrectionBySafetyNet) {\n mBestWord = typedWord;\n } else if (suggestedWords.hasAutoCorrectionWord()) {\n ...
"public Integer getIntegerValue() {\n if (getType() == null || !\"String_Node_Str\".equals(getType())) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n Integer res;\n if (values == null && values.isEmpty()) {\n res = null;\n } else {\n res = (Integer) values.iterato...
"public AvailableStatus requestFileInformation(DownloadLink parameter) throws Exception {\n this.setBrowserExclusive();\n br.getPage(parameter.getDownloadURL());\n if (br.containsHTML(\"String_Node_Str\"))\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n String filename = br.getRegex(\...
"public List<DomainVO> findAllChildren(String path, Long parentId) {\n SearchCriteria<DomainVO> sc = FindAllChildrenSearch.create();\n sc.setParameters(\"String_Node_Str\", path + \"String_Node_Str\");\n sc.setParameters(\"String_Node_Str\", parentId);\n return listBy(sc);\n}\n"
"private static void dedSecondLayerVariableUnificationTerms(final NAL nal, Task task, Sentence second_belief, final Stamp s, ArrayList<Term> terms_dependent, TruthValue truth, TruthValue t1, TruthValue t2, boolean strong) {\n Stamp sx = null;\n final Sentence taskSentence = task.sentence;\n for (int i = 0; i <...
"public long getHighId() {\n long genHighId = idGenerator != null ? idGenerator.getHighId() : -1;\n long updateHighId = highestUpdateRecordId;\n if (updateHighId > genHighId) {\n return updateHighId;\n }\n return genHighId;\n}\n"
"public boolean hasModifierInTree(DotNetModifier modifier) {\n IElementType iElementType = CSharpModifierListImplUtil.ourModifiers.get(CSharpModifier.as(modifier));\n return findChildByType(iElementType) != null;\n}\n"
"public static void launchPictureVideoLibrary(Fragment fragment) {\n Intent intent = new Intent(Intent.ACTION_PICK);\n intent.setType(\"String_Node_Str\");\n intent.putExtra(Intent.EXTRA_LOCAL_ONLY, true);\n fragment.startActivityForResult(intent, RequestCode.ACTIVITY_REQUEST_CODE_PICTURE_VIDEO_LIBRARY);\n}...
"private ReadRange adjustReadRange(ReadRange readRange, RunRecordMeta runRecord) {\n if (runRecord == null) {\n return readRange;\n }\n long fromTimeMillis = readRange.getFromMillis();\n long toTimeMillis = readRange.getToMillis();\n long runStartMillis = TimeUnit.SECONDS.toMillis(runRecord.getSta...
"private static String getSocketAddress(SocketAddress socketAddress) {\n String address = socketAddress.toString();\n int addressLength = address.length();\n if (addressLength > 0) {\n if (address.startsWith(\"String_Node_Str\")) {\n return address.substring(1);\n } else {\n ...
"public void upsert(Webhook webhook) {\n Map<String, AttributeValue> item = new HashMap<>();\n item.put(\"String_Node_Str\", new AttributeValue(webhook.getName()));\n item.put(\"String_Node_Str\", new AttributeValue(webhook.getCallbackUrl()));\n item.put(\"String_Node_Str\", new AttributeValue(webhook.getCh...
"private static boolean canMergeObjectsInJoin(ObjectType obj1, ObjectType obj2) {\n if (obj1.isTopObject() || obj2.isTopObject() || obj1.equals(obj2)) {\n return true;\n }\n NominalType nt1 = obj1.nominalType;\n NominalType nt2 = obj2.nominalType;\n if ((nt1.isBuiltinObject() || nt1.isLiteralObjec...
"private static Control findNextFilter() {\n if (lastFocusedIndex != -1) {\n Control lastFocused = FILTERS.get(lastFocusedIndex);\n if (!lastFocused.isFocused() && lastFocused.isVisible() && lastFocused.getScene() != null) {\n return lastFocused;\n }\n }\n int focused = findCurr...
"public static void main(String[] args) throws Exception {\n String inFile = null, outFile = null;\n boolean isPrintHelp = false, isPrintVersion = false, isPrintConfig = false;\n for (int i = 0; i < args.length; ++i) {\n String arg = args[i];\n switch(arg) {\n case \"String_Node_Str\":...
"public void onUserMessage(final UserMessageEvent event) {\n final String messageType = event.getMessageType();\n if (isChatMessage(messageType)) {\n final Page<?> page = event.getPage();\n final Visibility visibility = page.getVisibility();\n GWT.log(\"String_Node_Str\" + visibility);\n ...
"public void run() {\n StepMetaSearch.this.handleMetaSearch();\n}\n"
"public boolean postfire() throws IllegalActionException {\n boolean result = super.postfire();\n if (result && ModelExecutor.this._stopRequested) {\n result = false;\n }\n if (result && !_hasToken() && _eventQueue.isEmpty()) {\n result = false;\n }\n return result;\n}\n"
"private String createEmptyResponseMessage(String applicationName, long timeStamp) {\n StringBuilder emptyJsonMessage = new StringBuilder(32);\n emptyJsonMessage.append(\"String_Node_Str\");\n emptyJsonMessage.append(\"String_Node_Str\").append(APPLICATION_NAME).append(\"String_Node_Str\").append(\"String_Node...
"public void test_insert_with_id() {\n dao.clear(Pet.class);\n Pet pet = Pet.create(\"String_Node_Str\");\n pet.setId(9090);\n Dao dao = Daos.ext(this.dao, FieldFilter.create(Pet.class, FieldMatcher.make(null, null, true).setIgnoreId(false)));\n dao.fastInsert(pet);\n pet = dao.fetch(Pet.class);\n ...
"public static void main(String[] args) {\n Cell a = Cell.parseCif(new File(\"String_Node_Str\"));\n Cell b = Cell.parseCif(new File(\"String_Node_Str\"));\n System.out.println(a.matchesCell(b, 0.1, 0.1, 0.1));\n System.out.println(getFindsymOutput(b));\n}\n"
"public void testRangeRestrictionDistance() {\n given().param(\"String_Node_Str\", getParameter(\"String_Node_Str\")).param(\"String_Node_Str\", getParameter(\"String_Node_Str\")).param(\"String_Node_Str\", \"String_Node_Str\").param(\"String_Node_Str\", \"String_Node_Str\").when().get(getEndPointName()).then().stat...
"public boolean isBuiltInJavaType(JavaClass jClass) {\n String rawName = jClass.getRawName();\n return (getXMLToJavaTypeMap().containsKey(rawName) || rawName.startsWith(JAVA_PKG) || (rawName.startsWith(JAVAX_PKG) && !rawName.startsWith(JAVAX_WS_PKG)));\n}\n"
"protected Component buildMainPanel() {\n GridBagConstraints constraints = new GridBagConstraints();\n JPanel container = new JPanel(new GridBagLayout());\n LabelArea messageLabel = new LabelArea(resourceRepository().getString(this.messageKey));\n messageLabel.getAccessibleContext().setAccessibleName(messag...
"public void upload() throws SnapshotUploadException {\n verifyUploadParameters();\n Boolean error = Boolean.FALSE;\n ArrayBlockingQueue<SnapshotPart> partQueue = null;\n SnapshotPart part = null;\n SnapshotUploadInfo snapUploadInfo = null;\n Future<List<PartETag>> uploadPartsFuture = null;\n Futur...
"private void populateLists(Series series) {\n String[] componentsDisplayName = LiteralHelper.dataPointComponentTypeSet.getDisplayNames();\n try {\n IDataPointDefinition dpd = PluginSettings.instance().getDataPointDefinition(getSeriesForProcessing().getClass());\n if (dpd != null) {\n Str...
"public List<String> getVolumns() {\n List<String> volumns = new ArrayList<String>();\n for (DiskEntity disk : disks) {\n if (!DiskType.SWAP_DISK.getType().equals(disk.getDiskType()))\n volumns.add(disk.getDeviceName());\n }\n return volumns;\n}\n"
"List<CompositeBatch> groupBatches(List<Batch> batchList) {\n Map<BatchKey, CompositeBatch> batchGroups = new HashMap<BatchKey, CompositeBatch>();\n for (int i = 0; i < batchList.size(); i++) {\n for (int j = i + 1; j < batchList.size() && i < batchList.size(); ) {\n FastBatchingCellReader.Batch...
"public void shutdownThread() {\n try {\n isRunning = false;\n if (out != null)\n out.shutdownThread();\n stopOperation = true;\n this.interrupt();\n socket.close();\n connected = false;\n } catch (IOException e) {\n System.err.println(\"String_Node_Str\...
"public void testInvalidTransport() {\n thrown.expect(IllegalArgumentException.class);\n DnsOptions.newBuilder().setTransportOptions(EasyMock.createMock(TransportOptions.class));\n}\n"
"public boolean init(Filter filter, Graph graph) {\n boolean res = true;\n if (filter instanceof NodeFilter) {\n res = ((NodeFilter) filter).init(graph);\n } else if (filter instanceof EdgeFilter) {\n res = ((EdgeFilter) filter).init(graph);\n } else if (filter instanceof NodeFilter) {\n ...
"public boolean checkTrigger(GameEvent event, Game game) {\n if (((DamagedEvent) event).isCombatDamage() && event.getSourceId().equals(getSourceId())) {\n Permanent targetPermanet = game.getPermanentOrLKIBattlefield(event.getTargetId());\n if (targetPermanet.hasSubtype(SubType.DINOSAUR, game)) {\n ...
"public static CompatibilityChecker getChecker(Context ctx) {\n CompatibilityChecker checker;\n if (Utils.hasApi(5))\n checker = new EclairChecker(ctx);\n else\n checker = new BasicChecker();\n Log.d(\"String_Node_Str\", \"String_Node_Str\" + SDK_INT + \"String_Node_Str\" + checker.getClass()....
"public String getActualFormula() {\n FormulaPart formulaPart;\n StringBuilder actualFormulaBuilder = new StringBuilder();\n for (Iterator iterator = formulaParts.iterator(); iterator.hasNext(); ) {\n formulaPart = (FormulaPart) iterator.next();\n actualFormula += formulaPart.getActualFormula();\...
"public ServerResponse<User> getUserInfo(Integer userId) {\n User user = userMapper.selectByPrimaryKey(userId);\n if (user == null) {\n return ServerResponse.createByErrorMessage(\"String_Node_Str\");\n }\n user.setPassword(StringUtils.EMPTY);\n return ServerResponse.createBySuccess(user);\n}\n"
"public void addInformation(ItemStack itemStack, EntityPlayer entityPlayer, List list, boolean par4) {\n NBTTagCompound stackTag = itemStack.getTagCompound();\n if (stackTag != null) {\n NBTTagCompound activeTag = (NBTTagCompound) stackTag.getTag(ACTIVE_ITEMSTACK_TAG);\n String owner = stackTag.getS...
"public static void trySolution(Sentence belief, Task task, Memory memory) {\n Sentence problem = task.getSentence();\n Sentence oldBest = task.getBestSolution();\n float newQ = solutionQuality(problem, belief);\n if (oldBest != null) {\n float oldQ = solutionQuality(problem, oldBest);\n if (o...
"Address getSlot(ObjectReference object, int reference) throws InlinePragma {\n Address addr = object.toAddress();\n if (isReferenceArray)\n return addr.plus(VM.ARRAY_BASE_OFFSET).plus(reference << LOG_BYTES_IN_ADDRESS);\n else\n return addr.plus(offsets[reference]);\n}\n"
"private void setupComponentProperties() {\n if (connectionItem != null) {\n Connection connection = connectionItem.getConnection();\n if (connection instanceof GenericConnection) {\n GenericConnection genericConnection = (GenericConnection) connection;\n genericConnection.setComp...
"public void addToList(List list, Object value) {\n if (clustered) {\n ILock lock = null;\n try {\n IList ilist = (IList) list;\n lock = acquireDistributedLock(ilist.getName());\n ilist.add(value);\n } finally {\n releaseDistributedLock(lock);\n ...
"public static boolean isSame(String error1, String error2) {\n if (error1 == null && error2 == null) {\n return true;\n } else if (error1 == null || error2 == null) {\n return false;\n } else {\n if (error1.equals(error2)) {\n return true;\n }\n String lineSeparat...
"public void run() {\n try {\n KeyManagerFactory keyManagerFactory = KeyManagerFactory.getInstance(\"String_Node_Str\");\n keyManagerFactory.init(keyStore, password);\n TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(\"String_Node_Str\");\n trustManagerFactory.in...
"public boolean hasNextChild() {\n if (children == null) {\n return false;\n }\n if (currentChild < children.size()) {\n return true;\n }\n if (needRowGroups) {\n if (endOfGroups) {\n return false;\n }\n try {\n while (!endOfGroups) {\n ...
"public void check() throws EucalyptusCloudException {\n try {\n boolean notConnected = false;\n if (!isConnected()) {\n connectResource();\n if (!isConnected()) {\n LOG.warn(\"String_Node_Str\");\n notConnected = true;\n }\n }\n ...
"private void showSubcategoryPanel(CategoryInfo category) {\n if (listOfCategories == null)\n listOfCategories = new ArrayList<CategoryInfo>();\n selectIndicatorPanel(new ImageIcon(tnbbutton.getThumbNail(category.getImage())), category.getName());\n selectCategoryPanel(category.getID());\n if ((listO...
"public byte[] toBinary() {\n final byte[] indexRangesBinary = PersistenceUtils.toBinary(indexRanges);\n final ByteBuffer buf = ByteBuffer.allocate(5 + indexRangesBinary.length + binId.length);\n buf.put((byte) (fullExtent ? 1 : 0));\n buf.putInt(binId.length);\n buf.put(binId);\n buf.put(indexRangesB...