code
stringlengths
63
466k
code_sememe
stringlengths
141
3.79M
token_type
stringlengths
274
1.23M
public static <I> CompactDFA<I> minimizeDFA(DFA<?, I> dfa, Alphabet<I> alphabet) { return minimizeDFA(dfa, alphabet, PruningMode.PRUNE_AFTER); }
class class_name[name] begin[{] method[minimizeDFA, return_type[type[CompactDFA]], modifier[public static], parameter[dfa, alphabet]] begin[{] return[call[.minimizeDFA, parameter[member[.dfa], member[.alphabet], member[PruningMode.PRUNE_AFTER]]]] end[}] END[}]
Keyword[public] Keyword[static] operator[<] identifier[I] operator[>] identifier[CompactDFA] operator[<] identifier[I] operator[>] identifier[minimizeDFA] operator[SEP] identifier[DFA] operator[<] operator[?] , identifier[I] operator[>] identifier[dfa] , identifier[Alphabet] operator[<] identifier[I] operator[>] iden...
public static ErrorMessageFactory elementsShouldBeAtMost(Object actual, int times, Matcher<?> condition) { return new ElementsShouldBeAtMost(actual, times, condition); }
class class_name[name] begin[{] method[elementsShouldBeAtMost, return_type[type[ErrorMessageFactory]], modifier[public static], parameter[actual, times, condition]] begin[{] return[ClassCreator(arguments=[MemberReference(member=actual, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]...
Keyword[public] Keyword[static] identifier[ErrorMessageFactory] identifier[elementsShouldBeAtMost] operator[SEP] identifier[Object] identifier[actual] , Keyword[int] identifier[times] , identifier[Matcher] operator[<] operator[?] operator[>] identifier[condition] operator[SEP] { Keyword[return] Keyword[new] id...
public void addCoords(Point3d[] iAtoms, BoundingBox icoordbounds, Point3d[] jAtoms, BoundingBox jcoordbounds) { this.iAtoms = iAtoms; this.iAtomObjects = null; if (icoordbounds!=null) { this.ibounds = icoordbounds; } else { this.ibounds = new BoundingBox(this.iAtoms); } this.jAtoms = jAtoms; this....
class class_name[name] begin[{] method[addCoords, return_type[void], modifier[public], parameter[iAtoms, icoordbounds, jAtoms, jcoordbounds]] begin[{] assign[THIS[member[None.iAtoms]], member[.iAtoms]] assign[THIS[member[None.iAtomObjects]], literal[null]] if[bin...
Keyword[public] Keyword[void] identifier[addCoords] operator[SEP] identifier[Point3d] operator[SEP] operator[SEP] identifier[iAtoms] , identifier[BoundingBox] identifier[icoordbounds] , identifier[Point3d] operator[SEP] operator[SEP] identifier[jAtoms] , identifier[BoundingBox] identifier[jcoordbounds] operator[SEP]...
public final ContentSummary computeContentSummary() { long[] a = computeContentSummary(new long[]{0,0,0,0}); return new ContentSummary(a[0], a[1], a[2], getNsQuota(), a[3], getDsQuota()); }
class class_name[name] begin[{] method[computeContentSummary, return_type[type[ContentSummary]], modifier[final public], parameter[]] begin[{] local_variable[type[long], a] return[ClassCreator(arguments=[MemberReference(member=a, postfix_operators=[], prefix_operators=[], qualifier=, selectors=...
Keyword[public] Keyword[final] identifier[ContentSummary] identifier[computeContentSummary] operator[SEP] operator[SEP] { Keyword[long] operator[SEP] operator[SEP] identifier[a] operator[=] identifier[computeContentSummary] operator[SEP] Keyword[new] Keyword[long] operator[SEP] operator[SEP] { Other[0...
public int printOptions(Options options) { Collection<Option> optList = options.getAllOptions(); StringBuilder sb = new StringBuilder(); int leftWidth = 0; if (!options.isEmpty()) { leftWidth = renderOptions(sb, optList); if (sb.length() > 0) { if ...
class class_name[name] begin[{] method[printOptions, return_type[type[int]], modifier[public], parameter[options]] begin[{] local_variable[type[Collection], optList] local_variable[type[StringBuilder], sb] local_variable[type[int], leftWidth] if[call[options.isEmpty, par...
Keyword[public] Keyword[int] identifier[printOptions] operator[SEP] identifier[Options] identifier[options] operator[SEP] { identifier[Collection] operator[<] identifier[Option] operator[>] identifier[optList] operator[=] identifier[options] operator[SEP] identifier[getAllOptions] operator[SEP] operator[SEP] ope...
public static Builder newBuilderForEmulator(int port) { Builder builder = newBuilder().setProjectId("fake-project").setInstanceId("fake-instance"); builder .stubSettings() .setCredentialsProvider(NoCredentialsProvider.create()) .setEndpoint("localhost:" + port) .setTransportChan...
class class_name[name] begin[{] method[newBuilderForEmulator, return_type[type[Builder]], modifier[public static], parameter[port]] begin[{] local_variable[type[Builder], builder] call[builder.stubSettings, parameter[]] return[member[.builder]] end[}] END[}]
Keyword[public] Keyword[static] identifier[Builder] identifier[newBuilderForEmulator] operator[SEP] Keyword[int] identifier[port] operator[SEP] { identifier[Builder] identifier[builder] operator[=] identifier[newBuilder] operator[SEP] operator[SEP] operator[SEP] identifier[setProjectId] operator[SEP] literal[Str...
public static void setUserPreference( Element compViewNode, String attributeName, IPerson person) { Document doc = compViewNode.getOwnerDocument(); NodeList nodes = doc.getElementsByTagName("layout"); boolean layoutOwner = false; Attr attrib; Element e; // Se...
class class_name[name] begin[{] method[setUserPreference, return_type[void], modifier[public static], parameter[compViewNode, attributeName, person]] begin[{] local_variable[type[Document], doc] local_variable[type[NodeList], nodes] local_variable[type[boolean], layoutOwner] loc...
Keyword[public] Keyword[static] Keyword[void] identifier[setUserPreference] operator[SEP] identifier[Element] identifier[compViewNode] , identifier[String] identifier[attributeName] , identifier[IPerson] identifier[person] operator[SEP] { identifier[Document] identifier[doc] operator[=] identifier[compViewNode...
protected void notifyListeners() { Iterator it = listeners.iterator(); while (it.hasNext()) { ((ComponentListener) it.next()).componentActivated(this); } }
class class_name[name] begin[{] method[notifyListeners, return_type[void], modifier[protected], parameter[]] begin[{] local_variable[type[Iterator], it] while[call[it.hasNext, parameter[]]] begin[{] Cast(expression=MethodInvocation(arguments=[], member=next, post...
Keyword[protected] Keyword[void] identifier[notifyListeners] operator[SEP] operator[SEP] { identifier[Iterator] identifier[it] operator[=] identifier[listeners] operator[SEP] identifier[iterator] operator[SEP] operator[SEP] operator[SEP] Keyword[while] operator[SEP] identifier[it] operator[SEP] identifier[hasNex...
private void parseFields(Element e, Object o) { for (GoConfigFieldWriter field : new GoConfigClassWriter(o.getClass(), configCache, registry).getAllFields(o)) { field.setValueIfNotNull(e, o); } }
class class_name[name] begin[{] method[parseFields, return_type[void], modifier[private], parameter[e, o]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=e, postfix_operators=[], prefix_operators=[], qu...
Keyword[private] Keyword[void] identifier[parseFields] operator[SEP] identifier[Element] identifier[e] , identifier[Object] identifier[o] operator[SEP] { Keyword[for] operator[SEP] identifier[GoConfigFieldWriter] identifier[field] operator[:] Keyword[new] identifier[GoConfigClassWriter] operator[SEP] identifie...
private void buttonExportSettingsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonExportSettingsActionPerformed StringBuffer sb = new StringBuffer(); sb.append(clusteringAlgoPanel0.getStreamValueAsCLIString()+"\n"); sb.append(clusteringAlgoPanel0.getAlgorithm0ValueAsCLISt...
class class_name[name] begin[{] method[buttonExportSettingsActionPerformed, return_type[void], modifier[private], parameter[evt]] begin[{] local_variable[type[StringBuffer], sb] call[sb.append, parameter[binary_operation[call[clusteringAlgoPanel0.getStreamValueAsCLIString, parameter[]],...
Keyword[private] Keyword[void] identifier[buttonExportSettingsActionPerformed] operator[SEP] identifier[java] operator[SEP] identifier[awt] operator[SEP] identifier[event] operator[SEP] identifier[ActionEvent] identifier[evt] operator[SEP] { identifier[StringBuffer] identifier[sb] operator[=] Keyword[new] identi...
public static int getIdOrAllocateFor(String slashedClassName) { int id = getIdFor(slashedClassName); if (id == -1) { id = allocateId(slashedClassName); } return id; }
class class_name[name] begin[{] method[getIdOrAllocateFor, return_type[type[int]], modifier[public static], parameter[slashedClassName]] begin[{] local_variable[type[int], id] if[binary_operation[member[.id], ==, literal[1]]] begin[{] assign[member[.id], call[.al...
Keyword[public] Keyword[static] Keyword[int] identifier[getIdOrAllocateFor] operator[SEP] identifier[String] identifier[slashedClassName] operator[SEP] { Keyword[int] identifier[id] operator[=] identifier[getIdFor] operator[SEP] identifier[slashedClassName] operator[SEP] operator[SEP] Keyword[if] operator[SEP] i...
public void setUpToClass(final Class<?> clazz) { if (clazz != null) { final Object object = getObject(); if (object != null && !clazz.isInstance(object)) { throw new IllegalArgumentException("Specified class is not a superclass of the object"); } } ...
class class_name[name] begin[{] method[setUpToClass, return_type[void], modifier[public], parameter[clazz]] begin[{] if[binary_operation[member[.clazz], !=, literal[null]]] begin[{] local_variable[type[Object], object] if[binary_operation[binary_operation[mem...
Keyword[public] Keyword[void] identifier[setUpToClass] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifier[clazz] operator[SEP] { Keyword[if] operator[SEP] identifier[clazz] operator[!=] Other[null] operator[SEP] { Keyword[final] identifier[Object] identifier[...
private static Style.FillRule parseFillRule(String val) { if ("nonzero".equals(val)) return Style.FillRule.NonZero; if ("evenodd".equals(val)) return Style.FillRule.EvenOdd; return null; }
class class_name[name] begin[{] method[parseFillRule, return_type[type[Style]], modifier[private static], parameter[val]] begin[{] if[literal["nonzero"]] begin[{] return[member[Style.FillRule.NonZero]] else begin[{] None end[}] if[literal["evenodd"]] begin[{] ret...
Keyword[private] Keyword[static] identifier[Style] operator[SEP] identifier[FillRule] identifier[parseFillRule] operator[SEP] identifier[String] identifier[val] operator[SEP] { Keyword[if] operator[SEP] literal[String] operator[SEP] identifier[equals] operator[SEP] identifier[val] operator[SEP] operator[SEP] Key...
public void updateBlocks(World world, MBlockState state) { AxisAlignedBB[] aabbs = AABBUtils.getCollisionBoundingBoxes(world, state, true); for (AxisAlignedBB aabb : aabbs) { if (aabb == null) continue; for (BlockPos pos : BlockPosUtils.getAllInBox(aabb)) world.neighborChanged(pos, state.getBlock(...
class class_name[name] begin[{] method[updateBlocks, return_type[void], modifier[public], parameter[world, state]] begin[{] local_variable[type[AxisAlignedBB], aabbs] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=a...
Keyword[public] Keyword[void] identifier[updateBlocks] operator[SEP] identifier[World] identifier[world] , identifier[MBlockState] identifier[state] operator[SEP] { identifier[AxisAlignedBB] operator[SEP] operator[SEP] identifier[aabbs] operator[=] identifier[AABBUtils] operator[SEP] identifier[getCollisionBoun...
public Properties getAttributeValueAsEncryptedProperties(final String _key, final boolean _concatenate) throws EFapsException { final Properties properties = getAttributeValueAsProperties(_key, _concatenate); final StandardPBEStrin...
class class_name[name] begin[{] method[getAttributeValueAsEncryptedProperties, return_type[type[Properties]], modifier[public], parameter[_key, _concatenate]] begin[{] local_variable[type[Properties], properties] local_variable[type[StandardPBEStringEncryptor], encryptor] call[e...
Keyword[public] identifier[Properties] identifier[getAttributeValueAsEncryptedProperties] operator[SEP] Keyword[final] identifier[String] identifier[_key] , Keyword[final] Keyword[boolean] identifier[_concatenate] operator[SEP] Keyword[throws] identifier[EFapsException] { Keyword[final] identifier[Properties] i...
protected BigDecimal round(double val){ BigDecimal value = new BigDecimal(val); if(val!=0.0){ value = value.setScale(3, BigDecimal.ROUND_DOWN); } return value; }
class class_name[name] begin[{] method[round, return_type[type[BigDecimal]], modifier[protected], parameter[val]] begin[{] local_variable[type[BigDecimal], value] if[binary_operation[member[.val], !=, literal[0.0]]] begin[{] assign[member[.value], call[value.setS...
Keyword[protected] identifier[BigDecimal] identifier[round] operator[SEP] Keyword[double] identifier[val] operator[SEP] { identifier[BigDecimal] identifier[value] operator[=] Keyword[new] identifier[BigDecimal] operator[SEP] identifier[val] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[val] op...
public <RO> SingleRuleContext<DPO, Collection<DPO>, RO> check(Collection<Rule<Collection<DPO>, RO>> rules) { List<Rule<Collection<DPO>, RO>> addedRules = new ArrayList<Rule<Collection<DPO>, RO>>(); if (rules != null) { addedRules.addAll(rules); } // Change context re...
class class_name[name] begin[{] method[check, return_type[type[SingleRuleContext]], modifier[public], parameter[rules]] begin[{] local_variable[type[List], addedRules] if[binary_operation[member[.rules], !=, literal[null]]] begin[{] call[addedRules.addAll, parame...
Keyword[public] operator[<] identifier[RO] operator[>] identifier[SingleRuleContext] operator[<] identifier[DPO] , identifier[Collection] operator[<] identifier[DPO] operator[>] , identifier[RO] operator[>] identifier[check] operator[SEP] identifier[Collection] operator[<] identifier[Rule] operator[<] identifier[Coll...
private static AddOn getAddOn(Collection<AddOn> addOns, String id) { for (AddOn addOn : addOns) { if (addOn.getId().equals(id)) { return addOn; } } return null; }
class class_name[name] begin[{] method[getAddOn, return_type[type[AddOn]], modifier[private static], parameter[addOns, id]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[], member=getId, postfix_operators=[], prefix_operators=[], qua...
Keyword[private] Keyword[static] identifier[AddOn] identifier[getAddOn] operator[SEP] identifier[Collection] operator[<] identifier[AddOn] operator[>] identifier[addOns] , identifier[String] identifier[id] operator[SEP] { Keyword[for] operator[SEP] identifier[AddOn] identifier[addOn] operator[:] identifier[add...
protected void unassignFromUserObjectInDb(final Type _unassignType, final JAASSystem _jaasSystem, final AbstractUserObject _object) throws EFapsException { Connection con = null; try { con...
class class_name[name] begin[{] method[unassignFromUserObjectInDb, return_type[void], modifier[protected], parameter[_unassignType, _jaasSystem, _object]] begin[{] local_variable[type[Connection], con] TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(mem...
Keyword[protected] Keyword[void] identifier[unassignFromUserObjectInDb] operator[SEP] Keyword[final] identifier[Type] identifier[_unassignType] , Keyword[final] identifier[JAASSystem] identifier[_jaasSystem] , Keyword[final] identifier[AbstractUserObject] identifier[_object] operator[SEP] Keyword[throws] identifier[E...
public T watch(DeterministicKey accountKey) { checkState(accountPath == null, "either watch or accountPath"); this.watchingKey = accountKey; this.isFollowing = false; return self(); }
class class_name[name] begin[{] method[watch, return_type[type[T]], modifier[public], parameter[accountKey]] begin[{] call[.checkState, parameter[binary_operation[member[.accountPath], ==, literal[null]], literal["either watch or accountPath"]]] assign[THIS[member[None.watchingK...
Keyword[public] identifier[T] identifier[watch] operator[SEP] identifier[DeterministicKey] identifier[accountKey] operator[SEP] { identifier[checkState] operator[SEP] identifier[accountPath] operator[==] Other[null] , literal[String] operator[SEP] operator[SEP] Keyword[this] operator[SEP] identifier[watchingKey...
@Override public ListLaunchPathsResult listLaunchPaths(ListLaunchPathsRequest request) { request = beforeClientExecution(request); return executeListLaunchPaths(request); }
class class_name[name] begin[{] method[listLaunchPaths, return_type[type[ListLaunchPathsResult]], modifier[public], parameter[request]] begin[{] assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]] return[call[.executeListLaunchPaths, parameter[member[.req...
annotation[@] identifier[Override] Keyword[public] identifier[ListLaunchPathsResult] identifier[listLaunchPaths] operator[SEP] identifier[ListLaunchPathsRequest] identifier[request] operator[SEP] { identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] identifier[request] operator[SEP] o...
private boolean isAddToLoadBalancerSuspended(String asgAccountId, String asgName) { AutoScalingGroup asg; if(asgAccountId == null || asgAccountId.equals(accountId)) { asg = retrieveAutoScalingGroup(asgName); } else { asg = retrieveAutoScalingGroupCrossAccount(asgAccountId...
class class_name[name] begin[{] method[isAddToLoadBalancerSuspended, return_type[type[boolean]], modifier[private], parameter[asgAccountId, asgName]] begin[{] local_variable[type[AutoScalingGroup], asg] if[binary_operation[binary_operation[member[.asgAccountId], ==, literal[null]], ||, ...
Keyword[private] Keyword[boolean] identifier[isAddToLoadBalancerSuspended] operator[SEP] identifier[String] identifier[asgAccountId] , identifier[String] identifier[asgName] operator[SEP] { identifier[AutoScalingGroup] identifier[asg] operator[SEP] Keyword[if] operator[SEP] identifier[asgAccountId] operator[==]...
protected UtilImpl_BidirectionalMap getAnnotationsMap(ScanPolicy policy, AnnotationCategory category) { return getPolicyData(policy).getTargetData(category); }
class class_name[name] begin[{] method[getAnnotationsMap, return_type[type[UtilImpl_BidirectionalMap]], modifier[protected], parameter[policy, category]] begin[{] return[call[.getPolicyData, parameter[member[.policy]]]] end[}] END[}]
Keyword[protected] identifier[UtilImpl_BidirectionalMap] identifier[getAnnotationsMap] operator[SEP] identifier[ScanPolicy] identifier[policy] , identifier[AnnotationCategory] identifier[category] operator[SEP] { Keyword[return] identifier[getPolicyData] operator[SEP] identifier[policy] operator[SEP] operator[S...
@Nonnull @ReturnsMutableCopy public static ICommonsList <File> getDirectoryContent (@Nonnull final File aDirectory, @Nonnull final FilenameFilter aFilenameFilter) { ValueEnforcer.notNull (aDirectory, "Directory"); ValueEnforcer.notNull (aFilenameFil...
class class_name[name] begin[{] method[getDirectoryContent, return_type[type[ICommonsList]], modifier[public static], parameter[aDirectory, aFilenameFilter]] begin[{] call[ValueEnforcer.notNull, parameter[member[.aDirectory], literal["Directory"]]] call[ValueEnforcer.notNull, pa...
annotation[@] identifier[Nonnull] annotation[@] identifier[ReturnsMutableCopy] Keyword[public] Keyword[static] identifier[ICommonsList] operator[<] identifier[File] operator[>] identifier[getDirectoryContent] operator[SEP] annotation[@] identifier[Nonnull] Keyword[final] identifier[File] identifier[aDirectory] , annot...
protected void cacheExtension(URI uri) { // extract extension file name from URI String uriStr = uri.toString().toLowerCase(); if (uriStr.endsWith("/")) { uriStr = uriStr.substring(0, uriStr.length() - 1); } String f...
class class_name[name] begin[{] method[cacheExtension, return_type[void], modifier[protected], parameter[uri]] begin[{] local_variable[type[String], uriStr] if[call[uriStr.endsWith, parameter[literal["/"]]]] begin[{] assign[member[.uriStr], call[uriStr.substring,...
Keyword[protected] Keyword[void] identifier[cacheExtension] operator[SEP] identifier[URI] identifier[uri] operator[SEP] { identifier[String] identifier[uriStr] operator[=] identifier[uri] operator[SEP] identifier[toString] operator[SEP] operator[SEP] operator[SEP] identifier[toLowerCase] operator[SEP] operator[S...
public final void forInit() throws RecognitionException { int forInit_StartIndex = input.index(); ParserRuleReturnScope variableModifier12 =null; ParserRuleReturnScope type13 =null; try { if ( state.backtracking>0 && alreadyParsedRule(input, 101) ) { return; } // src/main/resources/org/drools/compiler/...
class class_name[name] begin[{] method[forInit, return_type[void], modifier[final public], parameter[]] begin[{] local_variable[type[int], forInit_StartIndex] local_variable[type[ParserRuleReturnScope], variableModifier12] local_variable[type[ParserRuleReturnScope], type13] TryS...
Keyword[public] Keyword[final] Keyword[void] identifier[forInit] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] { Keyword[int] identifier[forInit_StartIndex] operator[=] identifier[input] operator[SEP] identifier[index] operator[SEP] operator[SEP] operator[SEP] identifier[ParserRule...
private static int decode4to3(byte[] src, int len, byte[] dest, int offset) { // Example: Dk or Dk== if (len == 2 || (src[2] == EQUALS_SIGN && src[3] == EQUALS_SIGN)) { int outBuff = (valida...
class class_name[name] begin[{] method[decode4to3, return_type[type[int]], modifier[private static], parameter[src, len, dest, offset]] begin[{] if[binary_operation[binary_operation[member[.len], ==, literal[2]], ||, binary_operation[binary_operation[member[.src], ==, member[.EQUALS_SIGN]], &&,...
Keyword[private] Keyword[static] Keyword[int] identifier[decode4to3] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[src] , Keyword[int] identifier[len] , Keyword[byte] operator[SEP] operator[SEP] identifier[dest] , Keyword[int] identifier[offset] operator[SEP] { Keyword[if] operator[SEP] i...
public static ZooSchema schema(PersistenceManager pm) { DBTracer.logCall(ZooJdoHelper.class, pm); return ((PersistenceManagerImpl)pm).getSession().schema(); }
class class_name[name] begin[{] method[schema, return_type[type[ZooSchema]], modifier[public static], parameter[pm]] begin[{] call[DBTracer.logCall, parameter[ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type=ReferenceType(arguments=None, dimensions=None, ...
Keyword[public] Keyword[static] identifier[ZooSchema] identifier[schema] operator[SEP] identifier[PersistenceManager] identifier[pm] operator[SEP] { identifier[DBTracer] operator[SEP] identifier[logCall] operator[SEP] identifier[ZooJdoHelper] operator[SEP] Keyword[class] , identifier[pm] operator[SEP] operator[...
public static Category of(String description, Setting... settings) { return new Category(description, Group.of(settings)); }
class class_name[name] begin[{] method[of, return_type[type[Category]], modifier[public static], parameter[description, settings]] begin[{] return[ClassCreator(arguments=[MemberReference(member=description, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MethodInvocation(arguments...
Keyword[public] Keyword[static] identifier[Category] identifier[of] operator[SEP] identifier[String] identifier[description] , identifier[Setting] operator[...] identifier[settings] operator[SEP] { Keyword[return] Keyword[new] identifier[Category] operator[SEP] identifier[description] , identifier[Group] opera...
@Override public com.liferay.commerce.model.CPDefinitionInventory createCPDefinitionInventory( long CPDefinitionInventoryId) { return _cpDefinitionInventoryLocalService.createCPDefinitionInventory(CPDefinitionInventoryId); }
class class_name[name] begin[{] method[createCPDefinitionInventory, return_type[type[com]], modifier[public], parameter[CPDefinitionInventoryId]] begin[{] return[call[_cpDefinitionInventoryLocalService.createCPDefinitionInventory, parameter[member[.CPDefinitionInventoryId]]]] end[}] END[}]
annotation[@] identifier[Override] Keyword[public] identifier[com] operator[SEP] identifier[liferay] operator[SEP] identifier[commerce] operator[SEP] identifier[model] operator[SEP] identifier[CPDefinitionInventory] identifier[createCPDefinitionInventory] operator[SEP] Keyword[long] identifier[CPDefinitionInventoryId] ...
public static void setUtc(Date time) { setClock(Clock.fixed(time.toInstant(), ZoneId.of("UTC"))); }
class class_name[name] begin[{] method[setUtc, return_type[void], modifier[public static], parameter[time]] begin[{] call[.setClock, parameter[call[Clock.fixed, parameter[call[time.toInstant, parameter[]], call[ZoneId.of, parameter[literal["UTC"]]]]]]] end[}] END[}]
Keyword[public] Keyword[static] Keyword[void] identifier[setUtc] operator[SEP] identifier[Date] identifier[time] operator[SEP] { identifier[setClock] operator[SEP] identifier[Clock] operator[SEP] identifier[fixed] operator[SEP] identifier[time] operator[SEP] identifier[toInstant] operator[SEP] operator[SEP] , i...
protected void print(Object s) throws IOException { out.write(Convert.escapeUnicode(s.toString())); }
class class_name[name] begin[{] method[print, return_type[void], modifier[protected], parameter[s]] begin[{] call[out.write, parameter[call[Convert.escapeUnicode, parameter[call[s.toString, parameter[]]]]]] end[}] END[}]
Keyword[protected] Keyword[void] identifier[print] operator[SEP] identifier[Object] identifier[s] operator[SEP] Keyword[throws] identifier[IOException] { identifier[out] operator[SEP] identifier[write] operator[SEP] identifier[Convert] operator[SEP] identifier[escapeUnicode] operator[SEP] identifier[s] operator[...
public static GeometryTypeInfo readGeometryType(ByteReader reader) { // Read the single byte order byte byte byteOrderValue = reader.readByte(); ByteOrder byteOrder = byteOrderValue == 0 ? ByteOrder.BIG_ENDIAN : ByteOrder.LITTLE_ENDIAN; reader.setByteOrder(byteOrder); // Read the geometry type unsigned ...
class class_name[name] begin[{] method[readGeometryType, return_type[type[GeometryTypeInfo]], modifier[public static], parameter[reader]] begin[{] local_variable[type[byte], byteOrderValue] local_variable[type[ByteOrder], byteOrder] call[reader.setByteOrder, parameter[member[.by...
Keyword[public] Keyword[static] identifier[GeometryTypeInfo] identifier[readGeometryType] operator[SEP] identifier[ByteReader] identifier[reader] operator[SEP] { Keyword[byte] identifier[byteOrderValue] operator[=] identifier[reader] operator[SEP] identifier[readByte] operator[SEP] operator[SEP] operator[SEP] id...
public Complex subtract(Complex c) { Complex ret = new Complex(real, imag); ret.mutableSubtract(c); return ret; }
class class_name[name] begin[{] method[subtract, return_type[type[Complex]], modifier[public], parameter[c]] begin[{] local_variable[type[Complex], ret] call[ret.mutableSubtract, parameter[member[.c]]] return[member[.ret]] end[}] END[}]
Keyword[public] identifier[Complex] identifier[subtract] operator[SEP] identifier[Complex] identifier[c] operator[SEP] { identifier[Complex] identifier[ret] operator[=] Keyword[new] identifier[Complex] operator[SEP] identifier[real] , identifier[imag] operator[SEP] operator[SEP] identifier[ret] operator[SEP] id...
protected void checkAndAddListInjections(final BuildData buildData, final Document doc, final ITopicNode topicNode, final Map<String, TranslationDetails> translations) { final DocBookXMLPreProcessor preProcessor = buildData.getXMLPreProcessor(); final List<Integer> types = Ar...
class class_name[name] begin[{] method[checkAndAddListInjections, return_type[void], modifier[protected], parameter[buildData, doc, topicNode, translations]] begin[{] local_variable[type[DocBookXMLPreProcessor], preProcessor] local_variable[type[List], types] local_variable[type[HashMap...
Keyword[protected] Keyword[void] identifier[checkAndAddListInjections] operator[SEP] Keyword[final] identifier[BuildData] identifier[buildData] , Keyword[final] identifier[Document] identifier[doc] , Keyword[final] identifier[ITopicNode] identifier[topicNode] , Keyword[final] identifier[Map] operator[<] identifier[S...
public static <T extends MethodDescription> ElementMatcher.Junction<T> isOverriddenFrom(ElementMatcher<? super TypeDescription> matcher) { return isOverriddenFromGeneric(erasure(matcher)); }
class class_name[name] begin[{] method[isOverriddenFrom, return_type[type[ElementMatcher]], modifier[public static], parameter[matcher]] begin[{] return[call[.isOverriddenFromGeneric, parameter[call[.erasure, parameter[member[.matcher]]]]]] end[}] END[}]
Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[MethodDescription] operator[>] identifier[ElementMatcher] operator[SEP] identifier[Junction] operator[<] identifier[T] operator[>] identifier[isOverriddenFrom] operator[SEP] identifier[ElementMatcher] operator[<] operator[?] Keyword[s...
public static Vector getBitDouble(int[] data, int offset) throws Exception { Vector v = new Vector(); int type = ((Integer)getBits(data, 2, offset)).intValue(); int read = 2; double val = 0.0; if (type==0x00) { byte[] bytes = (byte[])getBits(data, 64, (offset+2)); ByteBuffer bb = ByteBuffer.wrap(bytes);...
class class_name[name] begin[{] method[getBitDouble, return_type[type[Vector]], modifier[public static], parameter[data, offset]] begin[{] local_variable[type[Vector], v] local_variable[type[int], type] local_variable[type[int], read] local_variable[type[double], val] ...
Keyword[public] Keyword[static] identifier[Vector] identifier[getBitDouble] operator[SEP] Keyword[int] operator[SEP] operator[SEP] identifier[data] , Keyword[int] identifier[offset] operator[SEP] Keyword[throws] identifier[Exception] { identifier[Vector] identifier[v] operator[=] Keyword[new] identifier[Vector]...
protected HealthResult getHealthResult() { HealthResult.Builder builder = HealthResult.builder(getName()); try { builder.details(getHealthInformation()); builder.status(this.healthStatus); } catch (Exception e) { builder.status(HealthStatus.DOWN); ...
class class_name[name] begin[{] method[getHealthResult, return_type[type[HealthResult]], modifier[protected], parameter[]] begin[{] local_variable[type[HealthResult], builder] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=ge...
Keyword[protected] identifier[HealthResult] identifier[getHealthResult] operator[SEP] operator[SEP] { identifier[HealthResult] operator[SEP] identifier[Builder] identifier[builder] operator[=] identifier[HealthResult] operator[SEP] identifier[builder] operator[SEP] identifier[getName] operator[SEP] operator[SEP]...
@Override public Object getObjectInstance(JavaColonNamespace namespace, String name) throws NamingException { // Get the ComponentMetaData for the currently active component. // There is no comp namespace if there is no active component. ComponentMetaData cmd = ComponentMetaDataAccessorImpl....
class class_name[name] begin[{] method[getObjectInstance, return_type[type[Object]], modifier[public], parameter[namespace, name]] begin[{] local_variable[type[ComponentMetaData], cmd] if[binary_operation[member[.cmd], ==, literal[null]]] begin[{] return[literal[null]] ...
annotation[@] identifier[Override] Keyword[public] identifier[Object] identifier[getObjectInstance] operator[SEP] identifier[JavaColonNamespace] identifier[namespace] , identifier[String] identifier[name] operator[SEP] Keyword[throws] identifier[NamingException] { identifier[ComponentMetaData] identifier[cmd] o...
public Observable<TopicSharedAccessKeysInner> regenerateKeyAsync(String resourceGroupName, String topicName, String keyName) { return regenerateKeyWithServiceResponseAsync(resourceGroupName, topicName, keyName).map(new Func1<ServiceResponse<TopicSharedAccessKeysInner>, TopicSharedAccessKeysInner>() { ...
class class_name[name] begin[{] method[regenerateKeyAsync, return_type[type[Observable]], modifier[public], parameter[resourceGroupName, topicName, keyName]] begin[{] return[call[.regenerateKeyWithServiceResponseAsync, parameter[member[.resourceGroupName], member[.topicName], member[.keyName]]]] en...
Keyword[public] identifier[Observable] operator[<] identifier[TopicSharedAccessKeysInner] operator[>] identifier[regenerateKeyAsync] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[topicName] , identifier[String] identifier[keyName] operator[SEP] { Keyword[return]...
public static String dateToStr(Date date, String format) { return new SimpleDateFormat(format).format(date); }
class class_name[name] begin[{] method[dateToStr, return_type[type[String]], modifier[public static], parameter[date, format]] begin[{] return[ClassCreator(arguments=[MemberReference(member=format, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], body=None, constructor_type_argume...
Keyword[public] Keyword[static] identifier[String] identifier[dateToStr] operator[SEP] identifier[Date] identifier[date] , identifier[String] identifier[format] operator[SEP] { Keyword[return] Keyword[new] identifier[SimpleDateFormat] operator[SEP] identifier[format] operator[SEP] operator[SEP] identifier[forma...
public void setRaidArrayIds(java.util.Collection<String> raidArrayIds) { if (raidArrayIds == null) { this.raidArrayIds = null; return; } this.raidArrayIds = new com.amazonaws.internal.SdkInternalList<String>(raidArrayIds); }
class class_name[name] begin[{] method[setRaidArrayIds, return_type[void], modifier[public], parameter[raidArrayIds]] begin[{] if[binary_operation[member[.raidArrayIds], ==, literal[null]]] begin[{] assign[THIS[member[None.raidArrayIds]], literal[null]] retur...
Keyword[public] Keyword[void] identifier[setRaidArrayIds] operator[SEP] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[Collection] operator[<] identifier[String] operator[>] identifier[raidArrayIds] operator[SEP] { Keyword[if] operator[SEP] identifier[raidArrayIds] operator[==] Other[nu...
@Override public UpdateUploadResult updateUpload(UpdateUploadRequest request) { request = beforeClientExecution(request); return executeUpdateUpload(request); }
class class_name[name] begin[{] method[updateUpload, return_type[type[UpdateUploadResult]], modifier[public], parameter[request]] begin[{] assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]] return[call[.executeUpdateUpload, parameter[member[.request]]]] ...
annotation[@] identifier[Override] Keyword[public] identifier[UpdateUploadResult] identifier[updateUpload] operator[SEP] identifier[UpdateUploadRequest] identifier[request] operator[SEP] { identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] identifier[request] operator[SEP] operator[S...
@Override public void emitted(Map<String, Object>log) { if (socket == null) return; ByteArrayOutputStream messageBuffer = new ByteArrayOutputStream(1024); Writer messageWriter = null; try { messageWriter = new OutputStreamWriter(messageBuffer, "utf-8"); JsonWriter jsonWriter = new JsonWr...
class class_name[name] begin[{] method[emitted, return_type[void], modifier[public], parameter[log]] begin[{] if[binary_operation[member[.socket], ==, literal[null]]] begin[{] return[None] else begin[{] None end[}] local_variable[type[ByteArrayOutputStream], messageBuffe...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[emitted] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[log] operator[SEP] { Keyword[if] operator[SEP] identifier[socket] operator[==] Other[null] operator[SEP] Keyword[return] o...
public boolean startup(String[] args) { if (args != null && args.length > 0 && args[0].equals("stop")) { shutdownHook.run(); return false; } // Do not call addShutdownHook inside Apache Commons Daemon Service Runner if (new Throwable().getStackTrace().length == 2) { Runtime.getRuntime().addShutd...
class class_name[name] begin[{] method[startup, return_type[type[boolean]], modifier[public], parameter[args]] begin[{] if[binary_operation[binary_operation[binary_operation[member[.args], !=, literal[null]], &&, binary_operation[member[args.length], >, literal[0]]], &&, member[.args]]] begin[{...
Keyword[public] Keyword[boolean] identifier[startup] operator[SEP] identifier[String] operator[SEP] operator[SEP] identifier[args] operator[SEP] { Keyword[if] operator[SEP] identifier[args] operator[!=] Other[null] operator[&&] identifier[args] operator[SEP] identifier[length] operator[>] Other[0] operator[&&] i...
public static String toJson(Calendar cal) { if (cal == null) { return NULL_VALUE; } CharBuf buffer = CharBuf.create(26); writeDate(cal.getTime(), buffer); return buffer.toString(); }
class class_name[name] begin[{] method[toJson, return_type[type[String]], modifier[public static], parameter[cal]] begin[{] if[binary_operation[member[.cal], ==, literal[null]]] begin[{] return[member[.NULL_VALUE]] else begin[{] None end[}] local_variable[typ...
Keyword[public] Keyword[static] identifier[String] identifier[toJson] operator[SEP] identifier[Calendar] identifier[cal] operator[SEP] { Keyword[if] operator[SEP] identifier[cal] operator[==] Other[null] operator[SEP] { Keyword[return] identifier[NULL_VALUE] operator[SEP] } identifier[Ch...
public DateTime plusDays(int days) { if (days == 0) { return this; } long instant = getChronology().days().add(getMillis(), days); return withMillis(instant); }
class class_name[name] begin[{] method[plusDays, return_type[type[DateTime]], modifier[public], parameter[days]] begin[{] if[binary_operation[member[.days], ==, literal[0]]] begin[{] return[THIS[]] else begin[{] None end[}] local_variable[type[long], instant]...
Keyword[public] identifier[DateTime] identifier[plusDays] operator[SEP] Keyword[int] identifier[days] operator[SEP] { Keyword[if] operator[SEP] identifier[days] operator[==] Other[0] operator[SEP] { Keyword[return] Keyword[this] operator[SEP] } Keyword[long] identifier[instant] operator[...
public static final Number getZeroForClazz(Class<? extends Number> clazz) { if (Double.class.isAssignableFrom(clazz) || Float.class.isAssignableFrom(clazz)) { // use doubleValue() return Double.valueOf(0d); } else { return Long.valueOf(0l); } }
class class_name[name] begin[{] method[getZeroForClazz, return_type[type[Number]], modifier[final public static], parameter[clazz]] begin[{] if[binary_operation[ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[MethodInvocation(arguments=[MemberReference(member=cl...
Keyword[public] Keyword[static] Keyword[final] identifier[Number] identifier[getZeroForClazz] operator[SEP] identifier[Class] operator[<] operator[?] Keyword[extends] identifier[Number] operator[>] identifier[clazz] operator[SEP] { Keyword[if] operator[SEP] identifier[Double] operator[SEP] Keyword[class] operato...
public SVNRepository repository(String urlstr) throws SVNException { ISVNAuthenticationManager authenticationManager; String userinfo; SVNURL url; int idx; String username; String password; url = SVNURL.parseURIEncoded(urlstr); userinfo = url.getUserInfo(...
class class_name[name] begin[{] method[repository, return_type[type[SVNRepository]], modifier[public], parameter[urlstr]] begin[{] local_variable[type[ISVNAuthenticationManager], authenticationManager] local_variable[type[String], userinfo] local_variable[type[SVNURL], url] loca...
Keyword[public] identifier[SVNRepository] identifier[repository] operator[SEP] identifier[String] identifier[urlstr] operator[SEP] Keyword[throws] identifier[SVNException] { identifier[ISVNAuthenticationManager] identifier[authenticationManager] operator[SEP] identifier[String] identifier[userinfo] operator[SEP]...
public void Divide(double scalar) { if (scalar == 0) { try { throw new ArithmeticException("Can not divide by zero."); } catch (Exception e) { e.printStackTrace(); } } this.real /= scalar; this.imaginary /= ...
class class_name[name] begin[{] method[Divide, return_type[void], modifier[public], parameter[scalar]] begin[{] if[binary_operation[member[.scalar], ==, literal[0]]] begin[{] TryStatement(block=[ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_o...
Keyword[public] Keyword[void] identifier[Divide] operator[SEP] Keyword[double] identifier[scalar] operator[SEP] { Keyword[if] operator[SEP] identifier[scalar] operator[==] Other[0] operator[SEP] { Keyword[try] { Keyword[throw] Keyword[new] identifier[ArithmeticException] operator[SEP] l...
public static <A extends Analyzer<?>> AnalyzerBeanDescriptor<A> ofAnalyzer(Class<A> analyzerClass) { return new AnnotationBasedAnalyzerBeanDescriptor<A>(analyzerClass); }
class class_name[name] begin[{] method[ofAnalyzer, return_type[type[AnalyzerBeanDescriptor]], modifier[public static], parameter[analyzerClass]] begin[{] return[ClassCreator(arguments=[MemberReference(member=analyzerClass, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], body=None...
Keyword[public] Keyword[static] operator[<] identifier[A] Keyword[extends] identifier[Analyzer] operator[<] operator[?] operator[>] operator[>] identifier[AnalyzerBeanDescriptor] operator[<] identifier[A] operator[>] identifier[ofAnalyzer] operator[SEP] identifier[Class] operator[<] identifier[A] operator[>] identifier...
public DescribeServicesRequest withServices(String... services) { if (this.services == null) { setServices(new com.amazonaws.internal.SdkInternalList<String>(services.length)); } for (String ele : services) { this.services.add(ele); } return this; }
class class_name[name] begin[{] method[withServices, return_type[type[DescribeServicesRequest]], modifier[public], parameter[services]] begin[{] if[binary_operation[THIS[member[None.services]], ==, literal[null]]] begin[{] call[.setServices, parameter[ClassCreator(argume...
Keyword[public] identifier[DescribeServicesRequest] identifier[withServices] operator[SEP] identifier[String] operator[...] identifier[services] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[services] operator[==] Other[null] operator[SEP] { identifier[setServices] o...
public void dispose() { if (onSubscribe.disposed.compareAndSet(false, true)) { for (Object chunk : onSubscribe.chunks) { ReferenceCountUtil.release(chunk); } onSubscribe.chunks.clear(); } }
class class_name[name] begin[{] method[dispose, return_type[void], modifier[public], parameter[]] begin[{] if[call[onSubscribe.disposed.compareAndSet, parameter[literal[false], literal[true]]]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(exp...
Keyword[public] Keyword[void] identifier[dispose] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[onSubscribe] operator[SEP] identifier[disposed] operator[SEP] identifier[compareAndSet] operator[SEP] literal[boolean] , literal[boolean] operator[SEP] operator[SEP] { Keyword[for] ope...
@Override public int size() { if (indics != null) { return indics.size(); } indics = new HashMap<Integer, Pair<Integer, Integer>>(); int size = 0; TestSequence rtests = repeat.getTests(); int count = rtests.size(); for (int r = from; r <= to; r++) { if (r == 0) { indics.put(size, new...
class class_name[name] begin[{] method[size, return_type[type[int]], modifier[public], parameter[]] begin[{] if[binary_operation[member[.indics], !=, literal[null]]] begin[{] return[call[indics.size, parameter[]]] else begin[{] None end[}] assign[memb...
annotation[@] identifier[Override] Keyword[public] Keyword[int] identifier[size] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[indics] operator[!=] Other[null] operator[SEP] { Keyword[return] identifier[indics] operator[SEP] identifier[size] operator[SEP] operator[SEP] operator[SE...
private boolean validBooleanExpression(Node expr) { if (isBooleanOperation(expr)) { return validBooleanOperation(expr); } if (!isOperation(expr)) { warnInvalidExpression("boolean", expr); return false; } if (!isValidPredicate(getCallName(expr))) { warnInvalid("boolean predic...
class class_name[name] begin[{] method[validBooleanExpression, return_type[type[boolean]], modifier[private], parameter[expr]] begin[{] if[call[.isBooleanOperation, parameter[member[.expr]]]] begin[{] return[call[.validBooleanOperation, parameter[member[.expr]]]] else begin[...
Keyword[private] Keyword[boolean] identifier[validBooleanExpression] operator[SEP] identifier[Node] identifier[expr] operator[SEP] { Keyword[if] operator[SEP] identifier[isBooleanOperation] operator[SEP] identifier[expr] operator[SEP] operator[SEP] { Keyword[return] identifier[validBooleanOperation] o...
@Override public void eSet(int featureID, Object newValue) { switch (featureID) { case AfplibPackage.BEGIN_IMAGE__OBJTYPE: setOBJTYPE((Integer)newValue); return; } super.eSet(featureID, newValue); }
class class_name[name] begin[{] method[eSet, return_type[void], modifier[public], parameter[featureID, newValue]] begin[{] SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=BEGIN_IMAGE__OBJTYPE, postfix_operators=[], prefix_operators=[], qualifier=AfplibPackage, selectors=[])], st...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[eSet] operator[SEP] Keyword[int] identifier[featureID] , identifier[Object] identifier[newValue] operator[SEP] { Keyword[switch] operator[SEP] identifier[featureID] operator[SEP] { Keyword[case] identifier[AfplibPackage] oper...
public String outputNameFor(String output) { Report report = openReport(output); return outputNameOf(report); }
class class_name[name] begin[{] method[outputNameFor, return_type[type[String]], modifier[public], parameter[output]] begin[{] local_variable[type[Report], report] return[call[.outputNameOf, parameter[member[.report]]]] end[}] END[}]
Keyword[public] identifier[String] identifier[outputNameFor] operator[SEP] identifier[String] identifier[output] operator[SEP] { identifier[Report] identifier[report] operator[=] identifier[openReport] operator[SEP] identifier[output] operator[SEP] operator[SEP] Keyword[return] identifier[outputNameOf] operator[...
public static int cufftExecR2C(cufftHandle plan, Pointer rIdata, Pointer cOdata) { return checkResult(cufftExecR2CNative(plan, rIdata, cOdata)); }
class class_name[name] begin[{] method[cufftExecR2C, return_type[type[int]], modifier[public static], parameter[plan, rIdata, cOdata]] begin[{] return[call[.checkResult, parameter[call[.cufftExecR2CNative, parameter[member[.plan], member[.rIdata], member[.cOdata]]]]]] end[}] END[}]
Keyword[public] Keyword[static] Keyword[int] identifier[cufftExecR2C] operator[SEP] identifier[cufftHandle] identifier[plan] , identifier[Pointer] identifier[rIdata] , identifier[Pointer] identifier[cOdata] operator[SEP] { Keyword[return] identifier[checkResult] operator[SEP] identifier[cufftExecR2CNative] ope...
protected static String makeFilename(File directory, final String keyspace, final String columnFamily) { final Set<Descriptor> existing = new HashSet<Descriptor>(); directory.list(new FilenameFilter() { public boolean accept(File dir, String name) { Pa...
class class_name[name] begin[{] method[makeFilename, return_type[type[String]], modifier[static protected], parameter[directory, keyspace, columnFamily]] begin[{] local_variable[type[Set], existing] call[directory.list, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annota...
Keyword[protected] Keyword[static] identifier[String] identifier[makeFilename] operator[SEP] identifier[File] identifier[directory] , Keyword[final] identifier[String] identifier[keyspace] , Keyword[final] identifier[String] identifier[columnFamily] operator[SEP] { Keyword[final] identifier[Set] operator[<] id...
void setsDateSeriesHiddenFlag(boolean hide) { m_hideSeriesInstances = hide; if (m_hideSeriesInstances) { m_toggleSeriesButton.addStyleName(OpenCmsTheme.BUTTON_PRESSED); } else { m_toggleSeriesButton.removeStyleName(OpenCmsTheme.BUTTON_PRESSED); } }
class class_name[name] begin[{] method[setsDateSeriesHiddenFlag, return_type[void], modifier[default], parameter[hide]] begin[{] assign[member[.m_hideSeriesInstances], member[.hide]] if[member[.m_hideSeriesInstances]] begin[{] call[m_toggleSeriesButton.ad...
Keyword[void] identifier[setsDateSeriesHiddenFlag] operator[SEP] Keyword[boolean] identifier[hide] operator[SEP] { identifier[m_hideSeriesInstances] operator[=] identifier[hide] operator[SEP] Keyword[if] operator[SEP] identifier[m_hideSeriesInstances] operator[SEP] { identifier[m_toggleSeriesButton] o...
static public ByteBuffer newDirectBuffer (long address, int size) { if (directByteBufferConstructor == null) throw new UnsupportedOperationException("No direct ByteBuffer constructor is available."); try { return directByteBufferConstructor.newInstance(address, size, null); } catch (Exception ex) { throw...
class class_name[name] begin[{] method[newDirectBuffer, return_type[type[ByteBuffer]], modifier[public static], parameter[address, size]] begin[{] if[binary_operation[member[.directByteBufferConstructor], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(pos...
Keyword[static] Keyword[public] identifier[ByteBuffer] identifier[newDirectBuffer] operator[SEP] Keyword[long] identifier[address] , Keyword[int] identifier[size] operator[SEP] { Keyword[if] operator[SEP] identifier[directByteBufferConstructor] operator[==] Other[null] operator[SEP] Keyword[throw] Keyword[new] ...
@Override public FullEntity<?> toEntity(final Object pojo) { if (pojo instanceof FullEntity<?>) { return (FullEntity<?>)pojo; } else { @SuppressWarnings("unchecked") final EntityMetadata<Object> meta = (EntityMetadata<Object>)ofy.factory().getMetadata(pojo.getClass()); return meta.save(pojo, new...
class class_name[name] begin[{] method[toEntity, return_type[type[FullEntity]], modifier[public], parameter[pojo]] begin[{] if[binary_operation[member[.pojo], instanceof, type[FullEntity]]] begin[{] return[Cast(expression=MemberReference(member=pojo, postfix_operators=[], prefix_ope...
annotation[@] identifier[Override] Keyword[public] identifier[FullEntity] operator[<] operator[?] operator[>] identifier[toEntity] operator[SEP] Keyword[final] identifier[Object] identifier[pojo] operator[SEP] { Keyword[if] operator[SEP] identifier[pojo] Keyword[instanceof] identifier[FullEntity] operator[<] ope...
public boolean processMVBasedQueryFix(StmtTableScan mvTableScan, Set<SchemaColumn> scanColumns, JoinNode joinTree, List<ParsedColInfo> displayColumns, List<ParsedColInfo> groupByColumns) { // Check valid cases first //@TODO if ( ! (mvTableScan instanceof StmtTargetTableScan)) { ...
class class_name[name] begin[{] method[processMVBasedQueryFix, return_type[type[boolean]], modifier[public], parameter[mvTableScan, scanColumns, joinTree, displayColumns, groupByColumns]] begin[{] if[binary_operation[member[.mvTableScan], instanceof, type[StmtTargetTableScan]]] begin[{] ...
Keyword[public] Keyword[boolean] identifier[processMVBasedQueryFix] operator[SEP] identifier[StmtTableScan] identifier[mvTableScan] , identifier[Set] operator[<] identifier[SchemaColumn] operator[>] identifier[scanColumns] , identifier[JoinNode] identifier[joinTree] , identifier[List] operator[<] identifier[ParsedCo...
private IStatus performResourceMove(CommonDropAdapter dropAdapter, IResource[] sources) { MultiStatus problems = new MultiStatus(PlatformUI.PLUGIN_ID, 1, WorkbenchNavigatorMessages.DropAdapter_problemsMoving, null); mergeStatus(problems, validateTarget(dropAdapter.getCurrentTarget(), dropAdapter.getCurre...
class class_name[name] begin[{] method[performResourceMove, return_type[type[IStatus]], modifier[private], parameter[dropAdapter, sources]] begin[{] local_variable[type[MultiStatus], problems] call[.mergeStatus, parameter[member[.problems], call[.validateTarget, parameter[call[dropAdapt...
Keyword[private] identifier[IStatus] identifier[performResourceMove] operator[SEP] identifier[CommonDropAdapter] identifier[dropAdapter] , identifier[IResource] operator[SEP] operator[SEP] identifier[sources] operator[SEP] { identifier[MultiStatus] identifier[problems] operator[=] Keyword[new] identifier[MultiS...
public boolean startsWith(Name prefix) { byte[] thisBytes = this.getByteArray(); int thisOffset = this.getByteOffset(); int thisLength = this.getByteLength(); byte[] prefixBytes = prefix.getByteArray(); int prefixOffset = prefix.getByteOffset(); int prefixLength =...
class class_name[name] begin[{] method[startsWith, return_type[type[boolean]], modifier[public], parameter[prefix]] begin[{] local_variable[type[byte], thisBytes] local_variable[type[int], thisOffset] local_variable[type[int], thisLength] local_variable[type[byte], prefixBytes] ...
Keyword[public] Keyword[boolean] identifier[startsWith] operator[SEP] identifier[Name] identifier[prefix] operator[SEP] { Keyword[byte] operator[SEP] operator[SEP] identifier[thisBytes] operator[=] Keyword[this] operator[SEP] identifier[getByteArray] operator[SEP] operator[SEP] operator[SEP] Keyword[int] identif...
public void reportSummary(@WillClose OutputStream out) throws IOException { XMLOutput xmlOutput = new OutputStreamXMLOutput(out); try { writeXML(xmlOutput); } finally { xmlOutput.finish(); } }
class class_name[name] begin[{] method[reportSummary, return_type[void], modifier[public], parameter[out]] begin[{] local_variable[type[XMLOutput], xmlOutput] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=xmlOutput, postfix_operators=[], p...
Keyword[public] Keyword[void] identifier[reportSummary] operator[SEP] annotation[@] identifier[WillClose] identifier[OutputStream] identifier[out] operator[SEP] Keyword[throws] identifier[IOException] { identifier[XMLOutput] identifier[xmlOutput] operator[=] Keyword[new] identifier[OutputStreamXMLOutput] operato...
public static List<Class<?>> getTypeArguments(Class<?> base, Class<?> implementation) { checkArgNotNull(base, "base"); checkArgNotNull(implementation, "implementation"); Map<Type, Type> resolvedTypes = new HashMap<Type, Type>(); // first we need to resolve all supertypes up to the requi...
class class_name[name] begin[{] method[getTypeArguments, return_type[type[List]], modifier[public static], parameter[base, implementation]] begin[{] call[.checkArgNotNull, parameter[member[.base], literal["base"]]] call[.checkArgNotNull, parameter[member[.implementation], litera...
Keyword[public] Keyword[static] identifier[List] operator[<] identifier[Class] operator[<] operator[?] operator[>] operator[>] identifier[getTypeArguments] operator[SEP] identifier[Class] operator[<] operator[?] operator[>] identifier[base] , identifier[Class] operator[<] operator[?] operator[>] identifier[implementat...
public static byte[] hex2byte(String str) { byte[] bytes = str.getBytes(); if ((bytes.length % 2) != 0) { throw new IllegalArgumentException(); } byte[] b2 = new byte[bytes.length / 2]; for (int n = 0; n < bytes.length; n += 2) { String item = new String(b...
class class_name[name] begin[{] method[hex2byte, return_type[type[byte]], modifier[public static], parameter[str]] begin[{] local_variable[type[byte], bytes] if[binary_operation[binary_operation[member[bytes.length], %, literal[2]], !=, literal[0]]] begin[{] ThrowStatement(e...
Keyword[public] Keyword[static] Keyword[byte] operator[SEP] operator[SEP] identifier[hex2byte] operator[SEP] identifier[String] identifier[str] operator[SEP] { Keyword[byte] operator[SEP] operator[SEP] identifier[bytes] operator[=] identifier[str] operator[SEP] identifier[getBytes] operator[SEP] operator[SEP] op...
static RestTemplate createRestTemplate(CredHubProperties properties, ClientHttpRequestFactory clientHttpRequestFactory) { RestTemplate restTemplate = new RestTemplate(); configureRestTemplate(restTemplate, properties.getUrl(), clientHttpRequestFactory); return restTemplate; }
class class_name[name] begin[{] method[createRestTemplate, return_type[type[RestTemplate]], modifier[static], parameter[properties, clientHttpRequestFactory]] begin[{] local_variable[type[RestTemplate], restTemplate] call[.configureRestTemplate, parameter[member[.restTemplate], call[pro...
Keyword[static] identifier[RestTemplate] identifier[createRestTemplate] operator[SEP] identifier[CredHubProperties] identifier[properties] , identifier[ClientHttpRequestFactory] identifier[clientHttpRequestFactory] operator[SEP] { identifier[RestTemplate] identifier[restTemplate] operator[=] Keyword[new] identi...
public static String getFileNameWithoutExtenxion(String fileName) { if (fileName==null){ return null; } else { int number=fileName.lastIndexOf('.'); if (number>=0){ return fileName.substring(0, number); } else { return fileName; } } }
class class_name[name] begin[{] method[getFileNameWithoutExtenxion, return_type[type[String]], modifier[public static], parameter[fileName]] begin[{] if[binary_operation[member[.fileName], ==, literal[null]]] begin[{] return[literal[null]] else begin[{] local_var...
Keyword[public] Keyword[static] identifier[String] identifier[getFileNameWithoutExtenxion] operator[SEP] identifier[String] identifier[fileName] operator[SEP] { Keyword[if] operator[SEP] identifier[fileName] operator[==] Other[null] operator[SEP] { Keyword[return] Other[null] operator[SEP] } ...
public static void main(String args[]) { boolean usePopup = false; for (int i = 0; i < args.length; i++) { if (args[i].equals("-usePopup")) usePopup = true; } try { store = XMLStore.createFromFile("ThreddsDatasetChooser", null); p = store.getPreferences(); } catch (IOExce...
class class_name[name] begin[{] method[main, return_type[void], modifier[public static], parameter[args]] begin[{] local_variable[type[boolean], usePopup] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MemberReference(member=args, postfix_operators=[], prefix_ope...
Keyword[public] Keyword[static] Keyword[void] identifier[main] operator[SEP] identifier[String] identifier[args] operator[SEP] operator[SEP] operator[SEP] { Keyword[boolean] identifier[usePopup] operator[=] literal[boolean] operator[SEP] Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] ...
private static TableModel entity2ModelWithConfig(Class<?> entityClass) { TableModel model; model = entity2ModelIgnoreConfigMethod(entityClass); Method method = null; try { method = entityClass.getMethod("config", TableModel.class); } catch (Exception e) {// NOSONAR } if (method != null) try { me...
class class_name[name] begin[{] method[entity2ModelWithConfig, return_type[type[TableModel]], modifier[private static], parameter[entityClass]] begin[{] local_variable[type[TableModel], model] assign[member[.model], call[.entity2ModelIgnoreConfigMethod, parameter[member[.entityClass]]]]...
Keyword[private] Keyword[static] identifier[TableModel] identifier[entity2ModelWithConfig] operator[SEP] identifier[Class] operator[<] operator[?] operator[>] identifier[entityClass] operator[SEP] { identifier[TableModel] identifier[model] operator[SEP] identifier[model] operator[=] identifier[entity2ModelIgnore...
static public Element selectParentElement(Element element, String parentName) { Element parentElement = (Element) element.getParentNode(); if (parentElement == null) { return null; } if (parentElement.getTagName().equals(parentName)) { return parentElement; } return selectParentElement(parentElement, ...
class class_name[name] begin[{] method[selectParentElement, return_type[type[Element]], modifier[public static], parameter[element, parentName]] begin[{] local_variable[type[Element], parentElement] if[binary_operation[member[.parentElement], ==, literal[null]]] begin[{] ret...
Keyword[static] Keyword[public] identifier[Element] identifier[selectParentElement] operator[SEP] identifier[Element] identifier[element] , identifier[String] identifier[parentName] operator[SEP] { identifier[Element] identifier[parentElement] operator[=] operator[SEP] identifier[Element] operator[SEP] identifi...
@Override public String[] getAvailabilityZones(String region) { return configInstance .getStringProperty( namespace + region + "." + CONFIG_AVAILABILITY_ZONE_PREFIX, DEFAULT_ZONE).get().split(URL_SEPARATOR); }
class class_name[name] begin[{] method[getAvailabilityZones, return_type[type[String]], modifier[public], parameter[region]] begin[{] return[call[configInstance.getStringProperty, parameter[binary_operation[binary_operation[binary_operation[member[.namespace], +, member[.region]], +, literal["."]], +, ...
annotation[@] identifier[Override] Keyword[public] identifier[String] operator[SEP] operator[SEP] identifier[getAvailabilityZones] operator[SEP] identifier[String] identifier[region] operator[SEP] { Keyword[return] identifier[configInstance] operator[SEP] identifier[getStringProperty] operator[SEP] identifier[na...
public double convertFromTo(AnalyticModel model, double optionMaturity, double optionStrike, double value, QuotingConvention fromQuotingConvention, QuotingConvention toQuotingConvention) { if(fromQuotingConvention.equals(toQuotingConvention)) { return value; } if(getDiscountCurve() == null) { throw new Il...
class class_name[name] begin[{] method[convertFromTo, return_type[type[double]], modifier[public], parameter[model, optionMaturity, optionStrike, value, fromQuotingConvention, toQuotingConvention]] begin[{] if[call[fromQuotingConvention.equals, parameter[member[.toQuotingConvention]]]] begin[{]...
Keyword[public] Keyword[double] identifier[convertFromTo] operator[SEP] identifier[AnalyticModel] identifier[model] , Keyword[double] identifier[optionMaturity] , Keyword[double] identifier[optionStrike] , Keyword[double] identifier[value] , identifier[QuotingConvention] identifier[fromQuotingConvention] , identif...
public java.util.List<java.util.Map<String, AttributeValue>> getKeys() { return keys; }
class class_name[name] begin[{] method[getKeys, return_type[type[java]], modifier[public], parameter[]] begin[{] return[member[.keys]] end[}] END[}]
Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[List] operator[<] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[AttributeValue] operator[>] operator[>] identifier[getKeys] operator[SEP] operator[SEP] {...
public SDVariable step(String name, SDVariable in, double cutoff) { validateNumerical("step", in); SDVariable ret = f().step(in, cutoff); return updateVariableNameAndReference(ret, name); }
class class_name[name] begin[{] method[step, return_type[type[SDVariable]], modifier[public], parameter[name, in, cutoff]] begin[{] call[.validateNumerical, parameter[literal["step"], member[.in]]] local_variable[type[SDVariable], ret] return[call[.updateVariableNameAndReference...
Keyword[public] identifier[SDVariable] identifier[step] operator[SEP] identifier[String] identifier[name] , identifier[SDVariable] identifier[in] , Keyword[double] identifier[cutoff] operator[SEP] { identifier[validateNumerical] operator[SEP] literal[String] , identifier[in] operator[SEP] operator[SEP] identi...
private boolean convertStructure(Structure s, StructureMembers sm ) { boolean hasHeap = false; for (StructureMembers.Member m : sm.getMembers()) { Variable v2 = s.findVariable(m.getName()); assert v2 != null; H5header.Vinfo vm = (H5header.Vinfo) v2.getSPobject(); // apparently each memb...
class class_name[name] begin[{] method[convertStructure, return_type[type[boolean]], modifier[private], parameter[s, sm]] begin[{] local_variable[type[boolean], hasHeap] ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclar...
Keyword[private] Keyword[boolean] identifier[convertStructure] operator[SEP] identifier[Structure] identifier[s] , identifier[StructureMembers] identifier[sm] operator[SEP] { Keyword[boolean] identifier[hasHeap] operator[=] literal[boolean] operator[SEP] Keyword[for] operator[SEP] identifier[StructureMembers] o...
public BindingBuilder<S, T, V> checking(Validator<? super T, ? extends V> targetValidator) { return new DefaultBindingBuilder<S, T, V>(getSource(), getSourceValidator(), getConverter(), targetValidator, getCallback()); }
class class_name[name] begin[{] method[checking, return_type[type[BindingBuilder]], modifier[public], parameter[targetValidator]] begin[{] return[ClassCreator(arguments=[MethodInvocation(arguments=[], member=getSource, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type_arguments=...
Keyword[public] identifier[BindingBuilder] operator[<] identifier[S] , identifier[T] , identifier[V] operator[>] identifier[checking] operator[SEP] identifier[Validator] operator[<] operator[?] Keyword[super] identifier[T] , operator[?] Keyword[extends] identifier[V] operator[>] identifier[targetValidator] operator[...
public int getInMemoryDataSize() { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(this, tc, "getInMemoryDataSize"); int dataSize; // If tuning has requested return the size of the message we reference, // then delegate to the message. Otherwise call our...
class class_name[name] begin[{] method[getInMemoryDataSize, return_type[type[int]], modifier[public], parameter[]] begin[{] if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{] call[SibTr.entry, parameter[THIS...
Keyword[public] Keyword[int] identifier[getInMemoryDataSize] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identifier[tc] operator[SEP] identifier[isEntryEnabled] operator[SEP] operator[SEP...
public final <VH extends RecyclerView.ViewHolder> BuilderType setAdapter( @Nullable final RecyclerView.Adapter<VH> adapter, @Nullable final RecyclerView.LayoutManager layoutManager, @Nullable final DialogInterface.OnClickListener listener) { getProduct().setAdapter(adapter, l...
class class_name[name] begin[{] method[setAdapter, return_type[type[BuilderType]], modifier[final public], parameter[adapter, layoutManager, listener]] begin[{] call[.getProduct, parameter[]] return[call[.self, parameter[]]] end[}] END[}]
Keyword[public] Keyword[final] operator[<] identifier[VH] Keyword[extends] identifier[RecyclerView] operator[SEP] identifier[ViewHolder] operator[>] identifier[BuilderType] identifier[setAdapter] operator[SEP] annotation[@] identifier[Nullable] Keyword[final] identifier[RecyclerView] operator[SEP] identifier[Adapter] o...
public void resizeEip(String eip, int newBandwidthInMbps) { this.resizeEip(new ResizeEipRequest().withEip(eip).withNewBandwidthInMbps(newBandwidthInMbps)); }
class class_name[name] begin[{] method[resizeEip, return_type[void], modifier[public], parameter[eip, newBandwidthInMbps]] begin[{] THIS[call[None.resizeEip, parameter[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=Non...
Keyword[public] Keyword[void] identifier[resizeEip] operator[SEP] identifier[String] identifier[eip] , Keyword[int] identifier[newBandwidthInMbps] operator[SEP] { Keyword[this] operator[SEP] identifier[resizeEip] operator[SEP] Keyword[new] identifier[ResizeEipRequest] operator[SEP] operator[SEP] operator[SEP] i...
public void addPort(TDefinitions description) { // Create the interfaces TPortType interfaceType = wsdlFactory.createTPortType(); description.getAnyTopLevelOptionalElement().add(interfaceType); String interfaceName = this.getControlProperty(MessageControl.INTERFACE_NAME); int...
class class_name[name] begin[{] method[addPort, return_type[void], modifier[public], parameter[description]] begin[{] local_variable[type[TPortType], interfaceType] call[description.getAnyTopLevelOptionalElement, parameter[]] local_variable[type[String], interfaceName] ...
Keyword[public] Keyword[void] identifier[addPort] operator[SEP] identifier[TDefinitions] identifier[description] operator[SEP] { identifier[TPortType] identifier[interfaceType] operator[=] identifier[wsdlFactory] operator[SEP] identifier[createTPortType] operator[SEP] operator[SEP] operator[SEP] identifier[descr...
public com.ibm.websphere.cache.CacheEntry getEntry(com.ibm.websphere.cache.EntryInfo ei) { return getEntry(ei, true); }
class class_name[name] begin[{] method[getEntry, return_type[type[com]], modifier[public], parameter[ei]] begin[{] return[call[.getEntry, parameter[member[.ei], literal[true]]]] end[}] END[}]
Keyword[public] identifier[com] operator[SEP] identifier[ibm] operator[SEP] identifier[websphere] operator[SEP] identifier[cache] operator[SEP] identifier[CacheEntry] identifier[getEntry] operator[SEP] identifier[com] operator[SEP] identifier[ibm] operator[SEP] identifier[websphere] operator[SEP] identifier[cache] oper...
public Production getProduction(int eventCode) { assert (eventCode >= 0 && eventCode < containers.size()); return containers.get(getNumberOfEvents() - 1 - eventCode); }
class class_name[name] begin[{] method[getProduction, return_type[type[Production]], modifier[public], parameter[eventCode]] begin[{] AssertStatement(condition=BinaryOperation(operandl=BinaryOperation(operandl=MemberReference(member=eventCode, postfix_operators=[], prefix_operators=[], qualifier=, sele...
Keyword[public] identifier[Production] identifier[getProduction] operator[SEP] Keyword[int] identifier[eventCode] operator[SEP] { Keyword[assert] operator[SEP] identifier[eventCode] operator[>=] Other[0] operator[&&] identifier[eventCode] operator[<] identifier[containers] operator[SEP] identifier[size] operator...
public static void trustAllSSLCertificates(HttpsURLConnection connection) { getTrustingSSLSocketFactory(); connection.setSSLSocketFactory(socketFactory); connection.setHostnameVerifier(new HostnameVerifier() { public boolean verify(String s, SSLSession sslSession) { r...
class class_name[name] begin[{] method[trustAllSSLCertificates, return_type[void], modifier[public static], parameter[connection]] begin[{] call[.getTrustingSSLSocketFactory, parameter[]] call[connection.setSSLSocketFactory, parameter[member[.socketFactory]]] cal...
Keyword[public] Keyword[static] Keyword[void] identifier[trustAllSSLCertificates] operator[SEP] identifier[HttpsURLConnection] identifier[connection] operator[SEP] { identifier[getTrustingSSLSocketFactory] operator[SEP] operator[SEP] operator[SEP] identifier[connection] operator[SEP] identifier[setSSLSocketFacto...
public String eatStringConstant() { if (!matchStringConstant()) throw new BadSyntaxException(); /* * The input string constant is a quoted string token likes 'str', and * its token type (ttype) is the quote character. So the string * constants are not converted to lower case. */ String s = ...
class class_name[name] begin[{] method[eatStringConstant, return_type[type[String]], modifier[public], parameter[]] begin[{] if[call[.matchStringConstant, parameter[]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[]...
Keyword[public] identifier[String] identifier[eatStringConstant] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] operator[!] identifier[matchStringConstant] operator[SEP] operator[SEP] operator[SEP] Keyword[throw] Keyword[new] identifier[BadSyntaxException] operator[SEP] operator[SEP] operator[SEP] ident...
protected void setCommentLabel(Long id, String caption, String value) { Map<String, String> valueMap = answers.get(id); if (valueMap == null) { valueMap = new LinkedHashMap<>(); } valueMap.put(caption, value); answers.put(id, valueMap); }
class class_name[name] begin[{] method[setCommentLabel, return_type[void], modifier[protected], parameter[id, caption, value]] begin[{] local_variable[type[Map], valueMap] if[binary_operation[member[.valueMap], ==, literal[null]]] begin[{] assign[member[.valueMap...
Keyword[protected] Keyword[void] identifier[setCommentLabel] operator[SEP] identifier[Long] identifier[id] , identifier[String] identifier[caption] , identifier[String] identifier[value] operator[SEP] { identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[valueMap] operat...
public static UserChannelUpdater updater(final String pathServiceSid, final String pathUserSid, final String pathChannelSid, final UserChannel.NotificationLevel notificationLevel) { ...
class class_name[name] begin[{] method[updater, return_type[type[UserChannelUpdater]], modifier[public static], parameter[pathServiceSid, pathUserSid, pathChannelSid, notificationLevel]] begin[{] return[ClassCreator(arguments=[MemberReference(member=pathServiceSid, postfix_operators=[], prefix_operator...
Keyword[public] Keyword[static] identifier[UserChannelUpdater] identifier[updater] operator[SEP] Keyword[final] identifier[String] identifier[pathServiceSid] , Keyword[final] identifier[String] identifier[pathUserSid] , Keyword[final] identifier[String] identifier[pathChannelSid] , Keyword[final] identifier[UserChan...
void getSingletonNames(Set<String> singletons) { for (Map.Entry<String, ConfigurationList<SimpleElement>> entry : configurationMap.entrySet()) { ConfigurationList<SimpleElement> list = entry.getValue(); if (!list.isEmpty() && !list.hasId()) { singletons.add(entry.getKey()...
class class_name[name] begin[{] method[getSingletonNames, return_type[void], modifier[default], parameter[singletons]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(a...
Keyword[void] identifier[getSingletonNames] operator[SEP] identifier[Set] operator[<] identifier[String] operator[>] identifier[singletons] operator[SEP] { Keyword[for] operator[SEP] identifier[Map] operator[SEP] identifier[Entry] operator[<] identifier[String] , identifier[ConfigurationList] operator[<] identi...
public SDVariable neq(String name, SDVariable x, double y) { validateNumerical("not equals (neq)", x); SDVariable result = f().neq(x, y); return updateVariableNameAndReference(result, name); }
class class_name[name] begin[{] method[neq, return_type[type[SDVariable]], modifier[public], parameter[name, x, y]] begin[{] call[.validateNumerical, parameter[literal["not equals (neq)"], member[.x]]] local_variable[type[SDVariable], result] return[call[.updateVariableNameAndRe...
Keyword[public] identifier[SDVariable] identifier[neq] operator[SEP] identifier[String] identifier[name] , identifier[SDVariable] identifier[x] , Keyword[double] identifier[y] operator[SEP] { identifier[validateNumerical] operator[SEP] literal[String] , identifier[x] operator[SEP] operator[SEP] identifier[SDV...
@Override public DescribeEffectivePatchesForPatchBaselineResult describeEffectivePatchesForPatchBaseline(DescribeEffectivePatchesForPatchBaselineRequest request) { request = beforeClientExecution(request); return executeDescribeEffectivePatchesForPatchBaseline(request); }
class class_name[name] begin[{] method[describeEffectivePatchesForPatchBaseline, return_type[type[DescribeEffectivePatchesForPatchBaselineResult]], modifier[public], parameter[request]] begin[{] assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]] return[c...
annotation[@] identifier[Override] Keyword[public] identifier[DescribeEffectivePatchesForPatchBaselineResult] identifier[describeEffectivePatchesForPatchBaseline] operator[SEP] identifier[DescribeEffectivePatchesForPatchBaselineRequest] identifier[request] operator[SEP] { identifier[request] operator[=] identifi...
public static void launchActivity(Activity context, Class<? extends Activity> activity, boolean closeCurrentActivity, Map<String, String> params) { Intent intent = new Intent(context, activity); if (params != null) { Bundle bundle = new Bundle(); for (Entry<String, String> param...
class class_name[name] begin[{] method[launchActivity, return_type[void], modifier[public static], parameter[context, activity, closeCurrentActivity, params]] begin[{] local_variable[type[Intent], intent] if[binary_operation[member[.params], !=, literal[null]]] begin[{] loca...
Keyword[public] Keyword[static] Keyword[void] identifier[launchActivity] operator[SEP] identifier[Activity] identifier[context] , identifier[Class] operator[<] operator[?] Keyword[extends] identifier[Activity] operator[>] identifier[activity] , Keyword[boolean] identifier[closeCurrentActivity] , identifier[Map] oper...
private boolean isPrevProbablyRelativePronoun(AnalyzedTokenReadings[] tokens, int i) { return i >= 3 && tokens[i-1].getToken().equals("das") && tokens[i-2].getToken().equals(",") && tokens[i-3].matchesPosTagRegex("SUB:...:SIN:NEU"); }
class class_name[name] begin[{] method[isPrevProbablyRelativePronoun, return_type[type[boolean]], modifier[private], parameter[tokens, i]] begin[{] return[binary_operation[binary_operation[binary_operation[binary_operation[member[.i], >=, literal[3]], &&, member[.tokens]], &&, member[.tokens]], &&, mem...
Keyword[private] Keyword[boolean] identifier[isPrevProbablyRelativePronoun] operator[SEP] identifier[AnalyzedTokenReadings] operator[SEP] operator[SEP] identifier[tokens] , Keyword[int] identifier[i] operator[SEP] { Keyword[return] identifier[i] operator[>=] Other[3] operator[&&] identifier[tokens] operator[SEP...
public <V extends Comparable<? super V>> Optional<T> maxBy(Function<? super T, ? extends V> keyExtractor) { return Box .asOptional(reduce(null, (PairBox<T, V> acc, T t) -> { V val = keyExtractor.apply(t); if (acc == null) return new...
class class_name[name] begin[{] method[maxBy, return_type[type[Optional]], modifier[public], parameter[keyExtractor]] begin[{] return[call[Box.asOptional, parameter[call[.reduce, parameter[literal[null], LambdaExpression(body=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dim...
Keyword[public] operator[<] identifier[V] Keyword[extends] identifier[Comparable] operator[<] operator[?] Keyword[super] identifier[V] operator[>] operator[>] identifier[Optional] operator[<] identifier[T] operator[>] identifier[maxBy] operator[SEP] identifier[Function] operator[<] operator[?] Keyword[super] identifier...
public void gotoFreshPosWritable1(int oldIndex, int newIndex, int xor) { stabilize(oldIndex); gotoFreshPosWritable0(oldIndex, newIndex, xor); }
class class_name[name] begin[{] method[gotoFreshPosWritable1, return_type[void], modifier[public], parameter[oldIndex, newIndex, xor]] begin[{] call[.stabilize, parameter[member[.oldIndex]]] call[.gotoFreshPosWritable0, parameter[member[.oldIndex], member[.newIndex], member[.xor...
Keyword[public] Keyword[void] identifier[gotoFreshPosWritable1] operator[SEP] Keyword[int] identifier[oldIndex] , Keyword[int] identifier[newIndex] , Keyword[int] identifier[xor] operator[SEP] { identifier[stabilize] operator[SEP] identifier[oldIndex] operator[SEP] operator[SEP] identifier[gotoFreshPosWritable...
public void marshall(TransformS3DataSource transformS3DataSource, ProtocolMarshaller protocolMarshaller) { if (transformS3DataSource == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(transformS3DataS...
class class_name[name] begin[{] method[marshall, return_type[void], modifier[public], parameter[transformS3DataSource, protocolMarshaller]] begin[{] if[binary_operation[member[.transformS3DataSource], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Lit...
Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[TransformS3DataSource] identifier[transformS3DataSource] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] { Keyword[if] operator[SEP] identifier[transformS3DataSource] operator[==] Other[null] operator[SEP] ...
public void toPdf(PdfWriter writer, OutputStream os) throws IOException { int n = writer.getNewObjectNumber(reader, number, generation); os.write(PdfEncodings.convertToBytes(new StringBuffer().append(n).append(" 0 R").toString(), null)); }
class class_name[name] begin[{] method[toPdf, return_type[void], modifier[public], parameter[writer, os]] begin[{] local_variable[type[int], n] call[os.write, parameter[call[PdfEncodings.convertToBytes, parameter[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, pos...
Keyword[public] Keyword[void] identifier[toPdf] operator[SEP] identifier[PdfWriter] identifier[writer] , identifier[OutputStream] identifier[os] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[int] identifier[n] operator[=] identifier[writer] operator[SEP] identifier[getNewObjectNumber] operator...
@Override public XBELTerm convert(Term source) { if (source == null) return null; XBELTerm xt = new XBELTerm(); FunctionEnum functionEnum = source.getFunctionEnum(); Function func = Function.fromValue(functionEnum.getDisplayValue()); xt.setFunction(func); List<BELO...
class class_name[name] begin[{] method[convert, return_type[type[XBELTerm]], modifier[public], parameter[source]] begin[{] if[binary_operation[member[.source], ==, literal[null]]] begin[{] return[literal[null]] else begin[{] None end[}] local_variable[type[XBELTerm], xt]...
annotation[@] identifier[Override] Keyword[public] identifier[XBELTerm] identifier[convert] operator[SEP] identifier[Term] identifier[source] operator[SEP] { Keyword[if] operator[SEP] identifier[source] operator[==] Other[null] operator[SEP] Keyword[return] Other[null] operator[SEP] identifier[XBELTerm] identifi...
private void recursivels(FileSystem fs, Path p, List<FileStatus> out) throws IOException { FileStatus fstatus = fs.getFileStatus(p); if (!fstatus.isDir()) { out.add(fstatus); return; } else { out.add(fstatus); FileStatus[] listStatus = fs.listStatus(p); for (FileStatus s...
class class_name[name] begin[{] method[recursivels, return_type[void], modifier[private], parameter[fs, p, out]] begin[{] local_variable[type[FileStatus], fstatus] if[call[fstatus.isDir, parameter[]]] begin[{] call[out.add, parameter[member[.fstatus]]] ...
Keyword[private] Keyword[void] identifier[recursivels] operator[SEP] identifier[FileSystem] identifier[fs] , identifier[Path] identifier[p] , identifier[List] operator[<] identifier[FileStatus] operator[>] identifier[out] operator[SEP] Keyword[throws] identifier[IOException] { identifier[FileStatus] identifier...