code
stringlengths
63
466k
code_sememe
stringlengths
141
3.79M
token_type
stringlengths
274
1.23M
public <T> T invoke(Object target, Object... args) { return ReflectUtil.invoke(target, method, args); }
class class_name[name] begin[{] method[invoke, return_type[type[T]], modifier[public], parameter[target, args]] begin[{] return[call[ReflectUtil.invoke, parameter[member[.target], member[.method], member[.args]]]] end[}] END[}]
Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[invoke] operator[SEP] identifier[Object] identifier[target] , identifier[Object] operator[...] identifier[args] operator[SEP] { Keyword[return] identifier[ReflectUtil] operator[SEP] identifier[invoke] operator[SEP] identifier[target]...
public int getNumberOfLabelsUsed() { if (labels != null && !labels.isEmpty()) return labels.size(); else return ((Long) (maxCount + 1)).intValue(); }
class class_name[name] begin[{] method[getNumberOfLabelsUsed, return_type[type[int]], modifier[public], parameter[]] begin[{] if[binary_operation[binary_operation[member[.labels], !=, literal[null]], &&, call[labels.isEmpty, parameter[]]]] begin[{] return[call[labels.size, parameter[]]] ...
Keyword[public] Keyword[int] identifier[getNumberOfLabelsUsed] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[labels] operator[!=] Other[null] operator[&&] operator[!] identifier[labels] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] Keyword[return] identifier[lab...
public static int poll(Selector selector, PollItem[] items, int count, long timeout) { Utils.checkArgument(items != null, "items have to be supplied for polling"); if (count == 0) { if (timeout <= 0) { return 0; } LockSupport.parkNanos(TimeUnit.NAN...
class class_name[name] begin[{] method[poll, return_type[type[int]], modifier[public static], parameter[selector, items, count, timeout]] begin[{] call[Utils.checkArgument, parameter[binary_operation[member[.items], !=, literal[null]], literal["items have to be supplied for polling"]]] ...
Keyword[public] Keyword[static] Keyword[int] identifier[poll] operator[SEP] identifier[Selector] identifier[selector] , identifier[PollItem] operator[SEP] operator[SEP] identifier[items] , Keyword[int] identifier[count] , Keyword[long] identifier[timeout] operator[SEP] { identifier[Utils] operator[SEP] identi...
public void info(@Nullable final String event, @Nullable final String message) { log(LogLevel.INFO, event, message, EMPTY_STRING_ARRAY, EMPTY_OBJECT_ARRAY, DEFAULT_THROWABLE); }
class class_name[name] begin[{] method[info, return_type[void], modifier[public], parameter[event, message]] begin[{] call[.log, parameter[member[LogLevel.INFO], member[.event], member[.message], member[.EMPTY_STRING_ARRAY], member[.EMPTY_OBJECT_ARRAY], member[.DEFAULT_THROWABLE]]] end[}] E...
Keyword[public] Keyword[void] identifier[info] operator[SEP] annotation[@] identifier[Nullable] Keyword[final] identifier[String] identifier[event] , annotation[@] identifier[Nullable] Keyword[final] identifier[String] identifier[message] operator[SEP] { identifier[log] operator[SEP] identifier[LogLevel] operat...
public void marshall(DeploymentOverview deploymentOverview, ProtocolMarshaller protocolMarshaller) { if (deploymentOverview == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(deploymentOverview.getPen...
class class_name[name] begin[{] method[marshall, return_type[void], modifier[public], parameter[deploymentOverview, protocolMarshaller]] begin[{] if[binary_operation[member[.deploymentOverview], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(p...
Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[DeploymentOverview] identifier[deploymentOverview] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] { Keyword[if] operator[SEP] identifier[deploymentOverview] operator[==] Other[null] operator[SEP] { ...
@Override public int doStartTag() throws JspException { // Retrieve the action bean and event handler to secure. ActionBean actionBean; if (bean == null) { // Search in page, request, session (if valid) and application scopes, in that order. actionBean = (ActionBean)pageContext.findAttribute(Stripes...
class class_name[name] begin[{] method[doStartTag, return_type[type[int]], modifier[public], parameter[]] begin[{] local_variable[type[ActionBean], actionBean] if[binary_operation[member[.bean], ==, literal[null]]] begin[{] assign[member[.actionBean], Cast(expres...
annotation[@] identifier[Override] Keyword[public] Keyword[int] identifier[doStartTag] operator[SEP] operator[SEP] Keyword[throws] identifier[JspException] { identifier[ActionBean] identifier[actionBean] operator[SEP] Keyword[if] operator[SEP] identifier[bean] operator[==] Other[null] operator[SEP] { ...
public LoggerDefinitionVersion withLoggers(Logger... loggers) { if (this.loggers == null) { setLoggers(new java.util.ArrayList<Logger>(loggers.length)); } for (Logger ele : loggers) { this.loggers.add(ele); } return this; }
class class_name[name] begin[{] method[withLoggers, return_type[type[LoggerDefinitionVersion]], modifier[public], parameter[loggers]] begin[{] if[binary_operation[THIS[member[None.loggers]], ==, literal[null]]] begin[{] call[.setLoggers, parameter[ClassCreator(arguments=...
Keyword[public] identifier[LoggerDefinitionVersion] identifier[withLoggers] operator[SEP] identifier[Logger] operator[...] identifier[loggers] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[loggers] operator[==] Other[null] operator[SEP] { identifier[setLoggers] opera...
public JSONObject getApiKey(String key, RequestOptions requestOptions) throws AlgoliaException { return client.getRequest("/1/indexes/" + encodedIndexName + "/keys/" + key, false, requestOptions); }
class class_name[name] begin[{] method[getApiKey, return_type[type[JSONObject]], modifier[public], parameter[key, requestOptions]] begin[{] return[call[client.getRequest, parameter[binary_operation[binary_operation[binary_operation[literal["/1/indexes/"], +, member[.encodedIndexName]], +, literal["/key...
Keyword[public] identifier[JSONObject] identifier[getApiKey] operator[SEP] identifier[String] identifier[key] , identifier[RequestOptions] identifier[requestOptions] operator[SEP] Keyword[throws] identifier[AlgoliaException] { Keyword[return] identifier[client] operator[SEP] identifier[getRequest] operator[SEP]...
public String getProperty(String strProperty) { String strValue = super.getProperty(strProperty); if (strValue == null) return this.getSharedTable().getProperty(strProperty); return strValue; }
class class_name[name] begin[{] method[getProperty, return_type[type[String]], modifier[public], parameter[strProperty]] begin[{] local_variable[type[String], strValue] if[binary_operation[member[.strValue], ==, literal[null]]] begin[{] return[THIS[call[None.getSharedTable, parameter[]]...
Keyword[public] identifier[String] identifier[getProperty] operator[SEP] identifier[String] identifier[strProperty] operator[SEP] { identifier[String] identifier[strValue] operator[=] Keyword[super] operator[SEP] identifier[getProperty] operator[SEP] identifier[strProperty] operator[SEP] operator[SEP] Keyword[if...
public static base_response disable(nitro_service client, servicegroup resource) throws Exception { servicegroup disableresource = new servicegroup(); disableresource.servicegroupname = resource.servicegroupname; disableresource.servername = resource.servername; disableresource.port = resource.port; disablere...
class class_name[name] begin[{] method[disable, return_type[type[base_response]], modifier[public static], parameter[client, resource]] begin[{] local_variable[type[servicegroup], disableresource] assign[member[disableresource.servicegroupname], member[resource.servicegroupname]] ...
Keyword[public] Keyword[static] identifier[base_response] identifier[disable] operator[SEP] identifier[nitro_service] identifier[client] , identifier[servicegroup] identifier[resource] operator[SEP] Keyword[throws] identifier[Exception] { identifier[servicegroup] identifier[disableresource] operator[=] Keyword[...
public Usage postSubscriptionUsage(final String subscriptionCode, final String addOnCode, final Usage usage) { return doPOST(Subscription.SUBSCRIPTION_RESOURCE + "/" + subscriptionCode + AddOn.ADDONS_RESOURCE + "/" +...
class class_name[name] begin[{] method[postSubscriptionUsage, return_type[type[Usage]], modifier[public], parameter[subscriptionCode, addOnCode, usage]] begin[{] return[call[.doPOST, parameter[binary_operation[binary_operation[binary_operation[binary_operation[binary_operation[binary_operation[member[S...
Keyword[public] identifier[Usage] identifier[postSubscriptionUsage] operator[SEP] Keyword[final] identifier[String] identifier[subscriptionCode] , Keyword[final] identifier[String] identifier[addOnCode] , Keyword[final] identifier[Usage] identifier[usage] operator[SEP] { Keyword[return] identifier[doPOST] oper...
@BetaApi public final Operation setNodeTemplateNodeGroup( ProjectZoneNodeGroupName nodeGroup, NodeGroupsSetNodeTemplateRequest nodeGroupsSetNodeTemplateRequestResource) { SetNodeTemplateNodeGroupHttpRequest request = SetNodeTemplateNodeGroupHttpRequest.newBuilder() .setNodeGroup(n...
class class_name[name] begin[{] method[setNodeTemplateNodeGroup, return_type[type[Operation]], modifier[final public], parameter[nodeGroup, nodeGroupsSetNodeTemplateRequestResource]] begin[{] local_variable[type[SetNodeTemplateNodeGroupHttpRequest], request] return[call[.setNodeTemplateNodeGrou...
annotation[@] identifier[BetaApi] Keyword[public] Keyword[final] identifier[Operation] identifier[setNodeTemplateNodeGroup] operator[SEP] identifier[ProjectZoneNodeGroupName] identifier[nodeGroup] , identifier[NodeGroupsSetNodeTemplateRequest] identifier[nodeGroupsSetNodeTemplateRequestResource] operator[SEP] { ...
static Object getValueFromToken(String pToken) { return ("true".equals(pToken)) ? Boolean.TRUE : Boolean.FALSE; }
class class_name[name] begin[{] method[getValueFromToken, return_type[type[Object]], modifier[static], parameter[pToken]] begin[{] return[TernaryExpression(condition=Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value="true"), if_false=MemberReference(member=FALSE, po...
Keyword[static] identifier[Object] identifier[getValueFromToken] operator[SEP] identifier[String] identifier[pToken] operator[SEP] { Keyword[return] operator[SEP] literal[String] operator[SEP] identifier[equals] operator[SEP] identifier[pToken] operator[SEP] operator[SEP] operator[?] identifier[Boolean] operator...
SPFTrigger getTrigger(long triggerId, String appPackageName) { String where = Contract._ID + " = ? AND " + Contract.COLUMN_APP_IDENTIFIER + " = ?"; String[] whereArgs = { Long.toString(triggerId), appPackageName }; Cursor c = getReadableDatabase().query(Contract.TABLE_NAME, null, where, whereArgs, null, null, nul...
class class_name[name] begin[{] method[getTrigger, return_type[type[SPFTrigger]], modifier[default], parameter[triggerId, appPackageName]] begin[{] local_variable[type[String], where] local_variable[type[String], whereArgs] local_variable[type[Cursor], c] if[call[c.moveT...
identifier[SPFTrigger] identifier[getTrigger] operator[SEP] Keyword[long] identifier[triggerId] , identifier[String] identifier[appPackageName] operator[SEP] { identifier[String] identifier[where] operator[=] identifier[Contract] operator[SEP] identifier[_ID] operator[+] literal[String] operator[+] identifier[C...
protected void initSystem() throws SlickException { initGL(); setMusicVolume(1.0f); setSoundVolume(1.0f); graphics = new Graphics(width, height); defaultFont = graphics.getFont(); }
class class_name[name] begin[{] method[initSystem, return_type[void], modifier[protected], parameter[]] begin[{] call[.initGL, parameter[]] call[.setMusicVolume, parameter[literal[1.0f]]] call[.setSoundVolume, parameter[literal[1.0f]]] assign[memb...
Keyword[protected] Keyword[void] identifier[initSystem] operator[SEP] operator[SEP] Keyword[throws] identifier[SlickException] { identifier[initGL] operator[SEP] operator[SEP] operator[SEP] identifier[setMusicVolume] operator[SEP] literal[Float] operator[SEP] operator[SEP] identifier[setSoundVolume] operator[SEP...
@NotNull public static <T> Comparator<T> thenComparing( @NotNull final Comparator<? super T> c1, @NotNull final Comparator<? super T> c2) { Objects.requireNonNull(c1); Objects.requireNonNull(c2); return new Comparator<T>() { @Override public i...
class class_name[name] begin[{] method[thenComparing, return_type[type[Comparator]], modifier[public static], parameter[c1, c2]] begin[{] call[Objects.requireNonNull, parameter[member[.c1]]] call[Objects.requireNonNull, parameter[member[.c2]]] return[ClassCreator(argumen...
annotation[@] identifier[NotNull] Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[Comparator] operator[<] identifier[T] operator[>] identifier[thenComparing] operator[SEP] annotation[@] identifier[NotNull] Keyword[final] identifier[Comparator] operator[<] operator[?] Keyword[super] iden...
private void startAsyncValidation() { CmsRpcAction<Map<String, CmsValidationResult>> action = new CmsRpcAction<Map<String, CmsValidationResult>>() { /** * @see org.opencms.gwt.client.rpc.CmsRpcAction#execute() */ @Override public void execute() { ...
class class_name[name] begin[{] method[startAsyncValidation, return_type[void], modifier[private], parameter[]] begin[{] local_variable[type[CmsRpcAction], action] call[action.execute, parameter[]] end[}] END[}]
Keyword[private] Keyword[void] identifier[startAsyncValidation] operator[SEP] operator[SEP] { identifier[CmsRpcAction] operator[<] identifier[Map] operator[<] identifier[String] , identifier[CmsValidationResult] operator[>] operator[>] identifier[action] operator[=] Keyword[new] identifier[CmsRpcAction] operato...
private void parseGlobalAttributes(DAS das, DodsV root, DODSNetcdfFile dodsfile) { List<DODSAttribute> atts = root.attributes; for (ucar.nc2.Attribute ncatt : atts) { rootGroup.addAttribute(ncatt); } // loop over attribute tables, collect global attributes Enumeration tableNames = das.getNam...
class class_name[name] begin[{] method[parseGlobalAttributes, return_type[void], modifier[private], parameter[das, root, dodsfile]] begin[{] local_variable[type[List], atts] ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[Membe...
Keyword[private] Keyword[void] identifier[parseGlobalAttributes] operator[SEP] identifier[DAS] identifier[das] , identifier[DodsV] identifier[root] , identifier[DODSNetcdfFile] identifier[dodsfile] operator[SEP] { identifier[List] operator[<] identifier[DODSAttribute] operator[>] identifier[atts] operator[=] i...
@Override public void mTokens() throws RecognitionException { // src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:8: ( WS | FLOAT | HEX | DECIMAL | STRING | TIME_INTERVAL | BOOL | NULL | AT | PLUS_ASSIGN | MINUS_ASSIGN | MULT_ASSIGN | DIV_ASSIGN | AND_ASSIGN | OR_ASSIGN | XOR_ASSIGN | MOD_ASSIGN | UNIFY | D...
class class_name[name] begin[{] method[mTokens, return_type[void], modifier[public], parameter[]] begin[{] local_variable[type[int], alt63] assign[member[.alt63], call[dfa63.predict, parameter[member[.input]]]] SwitchStatement(cases=[SwitchStatementCase(case=[Literal(postfix_ope...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[mTokens] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] { Keyword[int] identifier[alt63] operator[=] Other[57] operator[SEP] identifier[alt63] operator[=] identifier[dfa63] operator[SEP] identifier[predict] ...
@Deprecated public <T extends Client<I, O>, R extends Client<I, O>, I extends Request, O extends Response> ClientDecorationBuilder add(Class<I> requestType, Class<O> responseType, Function<T, R> decorator) { return add0(requestType, responseType, decorator); }
class class_name[name] begin[{] method[add, return_type[type[ClientDecorationBuilder]], modifier[public], parameter[requestType, responseType, decorator]] begin[{] return[call[.add0, parameter[member[.requestType], member[.responseType], member[.decorator]]]] end[}] END[}]
annotation[@] identifier[Deprecated] Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[Client] operator[<] identifier[I] , identifier[O] operator[>] , identifier[R] Keyword[extends] identifier[Client] operator[<] identifier[I] , identifier[O] operator[>] , identifier[I] Keyword[extends] identifi...
protected void publishResourceEvent( IPortletWindow portletWindow, HttpServletRequest httpServletRequest, long executionTime, boolean usedBrowserCache, boolean usedPortalCache) { final IPortletWindowId portletWindowId = portletWindow.getPortletWindowI...
class class_name[name] begin[{] method[publishResourceEvent, return_type[void], modifier[protected], parameter[portletWindow, httpServletRequest, executionTime, usedBrowserCache, usedPortalCache]] begin[{] local_variable[type[IPortletWindowId], portletWindowId] THIS[member[None.portalEv...
Keyword[protected] Keyword[void] identifier[publishResourceEvent] operator[SEP] identifier[IPortletWindow] identifier[portletWindow] , identifier[HttpServletRequest] identifier[httpServletRequest] , Keyword[long] identifier[executionTime] , Keyword[boolean] identifier[usedBrowserCache] , Keyword[boolean] identifier...
public void marshall(CreateServerRequest createServerRequest, ProtocolMarshaller protocolMarshaller) { if (createServerRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(createServerRequest.ge...
class class_name[name] begin[{] method[marshall, return_type[void], modifier[public], parameter[createServerRequest, protocolMarshaller]] begin[{] if[binary_operation[member[.createServerRequest], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal...
Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[CreateServerRequest] identifier[createServerRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] { Keyword[if] operator[SEP] identifier[createServerRequest] operator[==] Other[null] operator[SEP] { ...
public void assertNotEmpty(@Nullable Description description, @Nullable String actual) { assertNotNull(description, actual); if (actual.isEmpty()) { throw failures.failure(description, shouldNotBeEmpty()); } }
class class_name[name] begin[{] method[assertNotEmpty, return_type[void], modifier[public], parameter[description, actual]] begin[{] call[.assertNotNull, parameter[member[.description], member[.actual]]] if[call[actual.isEmpty, parameter[]]] begin[{] ThrowStatement(e...
Keyword[public] Keyword[void] identifier[assertNotEmpty] operator[SEP] annotation[@] identifier[Nullable] identifier[Description] identifier[description] , annotation[@] identifier[Nullable] identifier[String] identifier[actual] operator[SEP] { identifier[assertNotNull] operator[SEP] identifier[description] , ...
void deleteProjectDirsIfNecessary(final long newProjectSizeInBytes) { final long projectCacheMaxSizeInByte = (long) (this.projectCacheDir.getTotalSpace() * this.percentageOfDisk); final long start = System.currentTimeMillis(); final List<ProjectDirectoryMetadata> allProjects = loadAllProjects(); ...
class class_name[name] begin[{] method[deleteProjectDirsIfNecessary, return_type[void], modifier[default], parameter[newProjectSizeInBytes]] begin[{] local_variable[type[long], projectCacheMaxSizeInByte] local_variable[type[long], start] local_variable[type[List], allProjects] ...
Keyword[void] identifier[deleteProjectDirsIfNecessary] operator[SEP] Keyword[final] Keyword[long] identifier[newProjectSizeInBytes] operator[SEP] { Keyword[final] Keyword[long] identifier[projectCacheMaxSizeInByte] operator[=] operator[SEP] Keyword[long] operator[SEP] operator[SEP] Keyword[this] operator[SEP] id...
@Nullable public static String getWithoutPEMHeader (@Nullable final String sCertificate) { if (StringHelper.hasNoText (sCertificate)) return null; // Remove special begin and end stuff String sRealCertificate = sCertificate.trim (); /** * Handle certain misconfiguration issues. E.g. for...
class class_name[name] begin[{] method[getWithoutPEMHeader, return_type[type[String]], modifier[public static], parameter[sCertificate]] begin[{] if[call[StringHelper.hasNoText, parameter[member[.sCertificate]]]] begin[{] return[literal[null]] else begin[{] None end[}] l...
annotation[@] identifier[Nullable] Keyword[public] Keyword[static] identifier[String] identifier[getWithoutPEMHeader] operator[SEP] annotation[@] identifier[Nullable] Keyword[final] identifier[String] identifier[sCertificate] operator[SEP] { Keyword[if] operator[SEP] identifier[StringHelper] operator[SEP] identi...
@UnstableApi @SuppressWarnings("unchecked") public static <T> T staticMockMarker(Class<T> clazz) { for (StaticMockitoSession session : sessions) { T marker = session.staticMockMarker(clazz); if (marker != null) { return marker; } } ret...
class class_name[name] begin[{] method[staticMockMarker, return_type[type[T]], modifier[public static], parameter[clazz]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocatio...
annotation[@] identifier[UnstableApi] annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[T] identifier[staticMockMarker] operator[SEP] identifier[Class] operator[<] identifier[T] operator[>] identifier[c...
public PactDslJsonArray includesStr(String value) { body.put(value); matchers.addRule(rootPath + appendArrayIndex(0), includesMatcher(value)); return this; }
class class_name[name] begin[{] method[includesStr, return_type[type[PactDslJsonArray]], modifier[public], parameter[value]] begin[{] call[body.put, parameter[member[.value]]] call[matchers.addRule, parameter[binary_operation[member[.rootPath], +, call[.appendArrayIndex, paramet...
Keyword[public] identifier[PactDslJsonArray] identifier[includesStr] operator[SEP] identifier[String] identifier[value] operator[SEP] { identifier[body] operator[SEP] identifier[put] operator[SEP] identifier[value] operator[SEP] operator[SEP] identifier[matchers] operator[SEP] identifier[addRule] operator[SEP] i...
public Date getValueAsDate(final TimeZone tz) { long time = ((Date) value).getTime(); long offset; if(tz == null) { offset = TimeZone.getDefault().getRawOffset(); } else { offset = tz.getRawOffset(); } return new Date(time - offse...
class class_name[name] begin[{] method[getValueAsDate, return_type[type[Date]], modifier[public], parameter[tz]] begin[{] local_variable[type[long], time] local_variable[type[long], offset] if[binary_operation[member[.tz], ==, literal[null]]] begin[{] ass...
Keyword[public] identifier[Date] identifier[getValueAsDate] operator[SEP] Keyword[final] identifier[TimeZone] identifier[tz] operator[SEP] { Keyword[long] identifier[time] operator[=] operator[SEP] operator[SEP] identifier[Date] operator[SEP] identifier[value] operator[SEP] operator[SEP] identifier[getTime] oper...
public void addCollectionColumnMetadata(CollectionColumnInfo collectionColumnMetadata) { if (this.collectionColumnMetadatas == null) { this.collectionColumnMetadatas = new ArrayList<CollectionColumnInfo>(); } if (!collectionColumnMetadatas.contains(collectionColumnMetada...
class class_name[name] begin[{] method[addCollectionColumnMetadata, return_type[void], modifier[public], parameter[collectionColumnMetadata]] begin[{] if[binary_operation[THIS[member[None.collectionColumnMetadatas]], ==, literal[null]]] begin[{] assign[THIS[member[None.c...
Keyword[public] Keyword[void] identifier[addCollectionColumnMetadata] operator[SEP] identifier[CollectionColumnInfo] identifier[collectionColumnMetadata] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[collectionColumnMetadatas] operator[==] Other[null] operator[SEP] { ...
private boolean is(Type formalType, TypeVariable<?> declaration) { if (runtimeType.equals(formalType)) { return true; } if (formalType instanceof WildcardType) { WildcardType your = canonicalizeWildcardType(declaration, (WildcardType) formalType); // if "formalType" is <? extends Foo>, "th...
class class_name[name] begin[{] method[is, return_type[type[boolean]], modifier[private], parameter[formalType, declaration]] begin[{] if[call[runtimeType.equals, parameter[member[.formalType]]]] begin[{] return[literal[true]] else begin[{] None end[}] ...
Keyword[private] Keyword[boolean] identifier[is] operator[SEP] identifier[Type] identifier[formalType] , identifier[TypeVariable] operator[<] operator[?] operator[>] identifier[declaration] operator[SEP] { Keyword[if] operator[SEP] identifier[runtimeType] operator[SEP] identifier[equals] operator[SEP] identifie...
private EntityContainer getEntityContainer() throws ODataRenderException { EntityContainer entityContainer = entityDataModel.getEntityContainer(); if (entityContainer == null) { String message = "EntityContainer should not be null"; LOG.error(message); throw new OData...
class class_name[name] begin[{] method[getEntityContainer, return_type[type[EntityContainer]], modifier[private], parameter[]] begin[{] local_variable[type[EntityContainer], entityContainer] if[binary_operation[member[.entityContainer], ==, literal[null]]] begin[{] local_var...
Keyword[private] identifier[EntityContainer] identifier[getEntityContainer] operator[SEP] operator[SEP] Keyword[throws] identifier[ODataRenderException] { identifier[EntityContainer] identifier[entityContainer] operator[=] identifier[entityDataModel] operator[SEP] identifier[getEntityContainer] operator[SEP] ope...
@CheckReturnValue @BackpressureSupport(BackpressureKind.FULL) @SchedulerSupport(SchedulerSupport.NONE) public final Flowable<List<T>> buffer(int count) { return buffer(count, count); }
class class_name[name] begin[{] method[buffer, return_type[type[Flowable]], modifier[final public], parameter[count]] begin[{] return[call[.buffer, parameter[member[.count], member[.count]]]] end[}] END[}]
annotation[@] identifier[CheckReturnValue] annotation[@] identifier[BackpressureSupport] operator[SEP] identifier[BackpressureKind] operator[SEP] identifier[FULL] operator[SEP] annotation[@] identifier[SchedulerSupport] operator[SEP] identifier[SchedulerSupport] operator[SEP] identifier[NONE] operator[SEP] Keyword[publ...
@Nullable public static TtlRunnable get(@Nullable Runnable runnable, boolean releaseTtlValueReferenceAfterRun, boolean idempotent) { if (null == runnable) return null; if (runnable instanceof TtlEnhanced) { // avoid redundant decoration, and ensure idempotency if (idempotent...
class class_name[name] begin[{] method[get, return_type[type[TtlRunnable]], modifier[public static], parameter[runnable, releaseTtlValueReferenceAfterRun, idempotent]] begin[{] if[binary_operation[literal[null], ==, member[.runnable]]] begin[{] return[literal[null]] else begin[{] None ...
annotation[@] identifier[Nullable] Keyword[public] Keyword[static] identifier[TtlRunnable] identifier[get] operator[SEP] annotation[@] identifier[Nullable] identifier[Runnable] identifier[runnable] , Keyword[boolean] identifier[releaseTtlValueReferenceAfterRun] , Keyword[boolean] identifier[idempotent] operator[SEP] ...
private Locale getLocale(CmsXmlContent content) { List<Locale> locales = content.getLocales(); if (locales.contains(Locale.ENGLISH) || locales.isEmpty()) { return Locale.ENGLISH; } return locales.get(0); }
class class_name[name] begin[{] method[getLocale, return_type[type[Locale]], modifier[private], parameter[content]] begin[{] local_variable[type[List], locales] if[binary_operation[call[locales.contains, parameter[member[Locale.ENGLISH]]], ||, call[locales.isEmpty, parameter[]]]] begin[...
Keyword[private] identifier[Locale] identifier[getLocale] operator[SEP] identifier[CmsXmlContent] identifier[content] operator[SEP] { identifier[List] operator[<] identifier[Locale] operator[>] identifier[locales] operator[=] identifier[content] operator[SEP] identifier[getLocales] operator[SEP] operator[SEP] op...
void handleFileItemClick(ItemClickEvent event) { if (isEditing()) { stopEdit(); } else if (!event.isCtrlKey() && !event.isShiftKey()) { // don't interfere with multi-selection using control key String itemId = (String)event.getItemId(); CmsUUID structure...
class class_name[name] begin[{] method[handleFileItemClick, return_type[void], modifier[default], parameter[event]] begin[{] if[call[.isEditing, parameter[]]] begin[{] call[.stopEdit, parameter[]] else begin[{] if[binary_operation[call[event.isCtrlKey...
Keyword[void] identifier[handleFileItemClick] operator[SEP] identifier[ItemClickEvent] identifier[event] operator[SEP] { Keyword[if] operator[SEP] identifier[isEditing] operator[SEP] operator[SEP] operator[SEP] { identifier[stopEdit] operator[SEP] operator[SEP] operator[SEP] } Keyword[el...
public Observable<Page<TopLevelDomainInner>> listAsync() { return listWithServiceResponseAsync() .map(new Func1<ServiceResponse<Page<TopLevelDomainInner>>, Page<TopLevelDomainInner>>() { @Override public Page<TopLevelDomainInner> call(ServiceResponse<Page<TopLevelDoma...
class class_name[name] begin[{] method[listAsync, return_type[type[Observable]], modifier[public], parameter[]] begin[{] return[call[.listWithServiceResponseAsync, parameter[]]] end[}] END[}]
Keyword[public] identifier[Observable] operator[<] identifier[Page] operator[<] identifier[TopLevelDomainInner] operator[>] operator[>] identifier[listAsync] operator[SEP] operator[SEP] { Keyword[return] identifier[listWithServiceResponseAsync] operator[SEP] operator[SEP] operator[SEP] identifier[map] operator[S...
public TableRef presence(final OnPresence onPresence, final OnError onError) { context.presence(channel, onPresence, onError); return this; }
class class_name[name] begin[{] method[presence, return_type[type[TableRef]], modifier[public], parameter[onPresence, onError]] begin[{] call[context.presence, parameter[member[.channel], member[.onPresence], member[.onError]]] return[THIS[]] end[}] END[}]
Keyword[public] identifier[TableRef] identifier[presence] operator[SEP] Keyword[final] identifier[OnPresence] identifier[onPresence] , Keyword[final] identifier[OnError] identifier[onError] operator[SEP] { identifier[context] operator[SEP] identifier[presence] operator[SEP] identifier[channel] , identifier[onP...
private static void initStreams() { Log.info("Initializing Streams..."); MetadataCommand command = (MetadataCommand) PreConfigurationContext.getCommandByName("-metadata"); BatchCommand batchCommand = (BatchCommand) PreConfigurationContext.getCommandByName("-batchSize"); AsyncAnnotationAuditOutputStream async...
class class_name[name] begin[{] method[initStreams, return_type[void], modifier[private static], parameter[]] begin[{] call[Log.info, parameter[literal["Initializing Streams..."]]] local_variable[type[MetadataCommand], command] local_variable[type[BatchCommand], batchCommand] ...
Keyword[private] Keyword[static] Keyword[void] identifier[initStreams] operator[SEP] operator[SEP] { identifier[Log] operator[SEP] identifier[info] operator[SEP] literal[String] operator[SEP] operator[SEP] identifier[MetadataCommand] identifier[command] operator[=] operator[SEP] identifier[MetadataCommand] opera...
private static void watchFile(final File file, ResourceLoader resourceLoader, String resourcePaths) { LOGGER.info("监控文件:"+file.toString()); DirectoryWatcher.WatcherCallback watcherCallback = new DirectoryWatcher.WatcherCallback(){ private long lastExecute = System.currentTimeMillis(); ...
class class_name[name] begin[{] method[watchFile, return_type[void], modifier[private static], parameter[file, resourceLoader, resourcePaths]] begin[{] call[LOGGER.info, parameter[binary_operation[literal["监控文件:"], +, call[file.toString, parameter[]]]]] local_variable[type[DirectoryWatc...
Keyword[private] Keyword[static] Keyword[void] identifier[watchFile] operator[SEP] Keyword[final] identifier[File] identifier[file] , identifier[ResourceLoader] identifier[resourceLoader] , identifier[String] identifier[resourcePaths] operator[SEP] { identifier[LOGGER] operator[SEP] identifier[info] operator[S...
void checkIndex(int index, int fieldLength) { if (isOutOfBounds(index, fieldLength, capacity())) { throw new IndexOutOfBoundsException( String.format("index: %d, length: %d (expected: range(0, %d))", index, fieldLength, capacity())); } }
class class_name[name] begin[{] method[checkIndex, return_type[void], modifier[default], parameter[index, fieldLength]] begin[{] if[call[.isOutOfBounds, parameter[member[.index], member[.fieldLength], call[.capacity, parameter[]]]]] begin[{] ThrowStatement(expression=ClassCreator(ar...
Keyword[void] identifier[checkIndex] operator[SEP] Keyword[int] identifier[index] , Keyword[int] identifier[fieldLength] operator[SEP] { Keyword[if] operator[SEP] identifier[isOutOfBounds] operator[SEP] identifier[index] , identifier[fieldLength] , identifier[capacity] operator[SEP] operator[SEP] operator[SEP...
private void addStringContent(final Part part, final String content) throws MessagingException, UnsupportedEncodingException { final String contentType = part.getContentType(); final String encoding = EmailUtil.extractEncoding(contentType, StringPool.US_ASCII); final String disposition = part.getDisposition(); ...
class class_name[name] begin[{] method[addStringContent, return_type[void], modifier[private], parameter[part, content]] begin[{] local_variable[type[String], contentType] local_variable[type[String], encoding] local_variable[type[String], disposition] if[binary_operatio...
Keyword[private] Keyword[void] identifier[addStringContent] operator[SEP] Keyword[final] identifier[Part] identifier[part] , Keyword[final] identifier[String] identifier[content] operator[SEP] Keyword[throws] identifier[MessagingException] , identifier[UnsupportedEncodingException] { Keyword[final] identifier[...
@ObjectiveCName("findTextMessagesWithPeer:withQuery:") public Command<List<MessageSearchEntity>> findTextMessages(Peer peer, String query) { return callback -> modules.getSearchModule().findTextMessages(peer, query) .then(v -> callback.onResult(v)) .failure(e -> callback.onEr...
class class_name[name] begin[{] method[findTextMessages, return_type[type[Command]], modifier[public], parameter[peer, query]] begin[{] return[LambdaExpression(body=MethodInvocation(arguments=[], member=getSearchModule, postfix_operators=[], prefix_operators=[], qualifier=modules, selectors=[MethodInvo...
annotation[@] identifier[ObjectiveCName] operator[SEP] literal[String] operator[SEP] Keyword[public] identifier[Command] operator[<] identifier[List] operator[<] identifier[MessageSearchEntity] operator[>] operator[>] identifier[findTextMessages] operator[SEP] identifier[Peer] identifier[peer] , identifier[String] ide...
@Override public CommerceWarehouse fetchByPrimaryKey(Serializable primaryKey) { Serializable serializable = entityCache.getResult(CommerceWarehouseModelImpl.ENTITY_CACHE_ENABLED, CommerceWarehouseImpl.class, primaryKey); if (serializable == nullModel) { return null; } CommerceWarehouse commerceWarehou...
class class_name[name] begin[{] method[fetchByPrimaryKey, return_type[type[CommerceWarehouse]], modifier[public], parameter[primaryKey]] begin[{] local_variable[type[Serializable], serializable] if[binary_operation[member[.serializable], ==, member[.nullModel]]] begin[{] ret...
annotation[@] identifier[Override] Keyword[public] identifier[CommerceWarehouse] identifier[fetchByPrimaryKey] operator[SEP] identifier[Serializable] identifier[primaryKey] operator[SEP] { identifier[Serializable] identifier[serializable] operator[=] identifier[entityCache] operator[SEP] identifier[getResult] op...
public RunParams params(Map<String, Object> params) { if (params == null) { throw new NullPointerException("\"params\" parameter can not be null"); } this.params.putAll(params); return this; }
class class_name[name] begin[{] method[params, return_type[type[RunParams]], modifier[public], parameter[params]] begin[{] if[binary_operation[member[.params], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operato...
Keyword[public] identifier[RunParams] identifier[params] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[params] operator[SEP] { Keyword[if] operator[SEP] identifier[params] operator[==] Other[null] operator[SEP] { Keyword[throw] Keyword[new] i...
public <E> E findOneByProperty(final Class<E> entityType, final String name, final Object value) { return query(dbOom.entities().findByColumn(entityType, name, value)).autoClose().find(entityType); }
class class_name[name] begin[{] method[findOneByProperty, return_type[type[E]], modifier[public], parameter[entityType, name, value]] begin[{] return[call[.query, parameter[call[dbOom.entities, parameter[]]]]] end[}] END[}]
Keyword[public] operator[<] identifier[E] operator[>] identifier[E] identifier[findOneByProperty] operator[SEP] Keyword[final] identifier[Class] operator[<] identifier[E] operator[>] identifier[entityType] , Keyword[final] identifier[String] identifier[name] , Keyword[final] identifier[Object] identifier[value] opera...
public static ExtensibleConfigurationPersister createDomainXmlConfigurationPersister(final ConfigurationFile file, ExecutorService executorService, ExtensionRegistry extensionRegistry, final HostControllerEnvironment environment) { DomainXml domainXml = new DomainXml(Module.getBootModuleLoader(), executorServic...
class class_name[name] begin[{] method[createDomainXmlConfigurationPersister, return_type[type[ExtensibleConfigurationPersister]], modifier[public static], parameter[file, executorService, extensionRegistry, environment]] begin[{] local_variable[type[DomainXml], domainXml] local_variable[type[b...
Keyword[public] Keyword[static] identifier[ExtensibleConfigurationPersister] identifier[createDomainXmlConfigurationPersister] operator[SEP] Keyword[final] identifier[ConfigurationFile] identifier[file] , identifier[ExecutorService] identifier[executorService] , identifier[ExtensionRegistry] identifier[extensionRegis...
@Trivial protected void activate(ComponentContext context) throws Exception { Dictionary<String, ?> props = context.getProperties(); final boolean trace = TraceComponent.isAnyTracingEnabled(); if (trace && tc.isEntryEnabled()) Tr.entry(this, tc, "activate", props); desti...
class class_name[name] begin[{] method[activate, return_type[void], modifier[protected], parameter[context]] begin[{] local_variable[type[Dictionary], props] local_variable[type[boolean], trace] if[binary_operation[member[.trace], &&, call[tc.isEntryEnabled, parameter[]]]] begin...
annotation[@] identifier[Trivial] Keyword[protected] Keyword[void] identifier[activate] operator[SEP] identifier[ComponentContext] identifier[context] operator[SEP] Keyword[throws] identifier[Exception] { identifier[Dictionary] operator[<] identifier[String] , operator[?] operator[>] identifier[props] operator[...
public java.util.List<FlowLog> getFlowLogs() { if (flowLogs == null) { flowLogs = new com.amazonaws.internal.SdkInternalList<FlowLog>(); } return flowLogs; }
class class_name[name] begin[{] method[getFlowLogs, return_type[type[java]], modifier[public], parameter[]] begin[{] if[binary_operation[member[.flowLogs], ==, literal[null]]] begin[{] assign[member[.flowLogs], ClassCreator(arguments=[], body=None, constructor_type_argum...
Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[List] operator[<] identifier[FlowLog] operator[>] identifier[getFlowLogs] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[flowLogs] operator[==] Other[null] operator[SEP] { identifier[flowLogs] ...
private List<GovernmentBodyAnnualOutcomeSummary> getGovernmentBodyList() { final List<GovernmentBodyAnnualOutcomeSummary> result = new ArrayList<>(); try { result.addAll(esvGovernmentBodyOperationOutcomeReader.readIncomeCsv()); result.addAll(esvGovernmentBodyOperationOutcomeReader.readOutgoingCsv()); } catc...
class class_name[name] begin[{] method[getGovernmentBodyList, return_type[type[List]], modifier[private], parameter[]] begin[{] local_variable[type[List], result] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=readIncomeCsv, ...
Keyword[private] identifier[List] operator[<] identifier[GovernmentBodyAnnualOutcomeSummary] operator[>] identifier[getGovernmentBodyList] operator[SEP] operator[SEP] { Keyword[final] identifier[List] operator[<] identifier[GovernmentBodyAnnualOutcomeSummary] operator[>] identifier[result] operator[=] Keyword[ne...
public String[] getIdentifiers() { final PerSessionInfo[] infos; synchronized (sessions) { infos = (PerSessionInfo[]) sessions.values().toArray(new PerSessionInfo[sessions.size()]); } int count = 0; for (int i = 0; i < infos.length; ++i) { if (infos[i] != null && infos[i].identifier != null) { ...
class class_name[name] begin[{] method[getIdentifiers, return_type[type[String]], modifier[public], parameter[]] begin[{] local_variable[type[PerSessionInfo], infos] SYNCHRONIZED[member[.sessions]] BEGIN[{] assign[member[.infos], Cast(expression=MethodInvocation(...
Keyword[public] identifier[String] operator[SEP] operator[SEP] identifier[getIdentifiers] operator[SEP] operator[SEP] { Keyword[final] identifier[PerSessionInfo] operator[SEP] operator[SEP] identifier[infos] operator[SEP] Keyword[synchronized] operator[SEP] identifier[sessions] operator[SEP] { identif...
protected Record locateRecord (int key) { int index = Math.abs(key)%_buckets.length; for (Record rec = _buckets[index]; rec != null; rec = rec.next) { if (rec.key == key) { return rec; } } return null; }
class class_name[name] begin[{] method[locateRecord, return_type[type[Record]], modifier[protected], parameter[key]] begin[{] local_variable[type[int], index] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=key, post...
Keyword[protected] identifier[Record] identifier[locateRecord] operator[SEP] Keyword[int] identifier[key] operator[SEP] { Keyword[int] identifier[index] operator[=] identifier[Math] operator[SEP] identifier[abs] operator[SEP] identifier[key] operator[SEP] operator[%] identifier[_buckets] operator[SEP] identifier...
public java.util.List<ResultAttribute> getResultAttributes() { if (resultAttributes == null) { resultAttributes = new com.amazonaws.internal.SdkInternalList<ResultAttribute>(); } return resultAttributes; }
class class_name[name] begin[{] method[getResultAttributes, return_type[type[java]], modifier[public], parameter[]] begin[{] if[binary_operation[member[.resultAttributes], ==, literal[null]]] begin[{] assign[member[.resultAttributes], ClassCreator(arguments=[], body=None...
Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[List] operator[<] identifier[ResultAttribute] operator[>] identifier[getResultAttributes] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[resultAttributes] operator[==] Other[null] operator[SEP] { ...
protected void checkAlert(Page page) throws FailureException { if (!DriverFactory.IE.equals(Context.getBrowser())) { final String txt = getAlertMessage(); if (txt != null) { new Result.Failure<>(txt, Messages.getMessage(Messages.FAIL_MESSAGE_ALERT_FOUND), true, page.g...
class class_name[name] begin[{] method[checkAlert, return_type[void], modifier[protected], parameter[page]] begin[{] if[call[DriverFactory.IE.equals, parameter[call[Context.getBrowser, parameter[]]]]] begin[{] local_variable[type[String], txt] if[binary_opera...
Keyword[protected] Keyword[void] identifier[checkAlert] operator[SEP] identifier[Page] identifier[page] operator[SEP] Keyword[throws] identifier[FailureException] { Keyword[if] operator[SEP] operator[!] identifier[DriverFactory] operator[SEP] identifier[IE] operator[SEP] identifier[equals] operator[SEP] identifi...
private Date stdDateTimeFormat(String text) throws java.text.ParseException { text = (text == null) ? "" : text.trim(); stdDateTimeFormat(); return stdDateTimeFormat.parse(text); }
class class_name[name] begin[{] method[stdDateTimeFormat, return_type[type[Date]], modifier[private], parameter[text]] begin[{] assign[member[.text], TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=text, postfix_operators=[], prefix_operators=[], qualifier=, selector...
Keyword[private] identifier[Date] identifier[stdDateTimeFormat] operator[SEP] identifier[String] identifier[text] operator[SEP] Keyword[throws] identifier[java] operator[SEP] identifier[text] operator[SEP] identifier[ParseException] { identifier[text] operator[=] operator[SEP] identifier[text] operator[==] Other...
@Nullable public final AnalyzedTokenReadings[] getUnifiedTokens() { if (tokSequence.isEmpty()) { return null; } List<AnalyzedTokenReadings> uTokens = new ArrayList<>(); for (int j = 0; j < tokSequence.size(); j++) { boolean unifiedTokensFound = false; // assume that nothing has been found ...
class class_name[name] begin[{] method[getUnifiedTokens, return_type[type[AnalyzedTokenReadings]], modifier[final public], parameter[]] begin[{] if[call[tokSequence.isEmpty, parameter[]]] begin[{] return[literal[null]] else begin[{] None end[}] local_variable...
annotation[@] identifier[Nullable] Keyword[public] Keyword[final] identifier[AnalyzedTokenReadings] operator[SEP] operator[SEP] identifier[getUnifiedTokens] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[tokSequence] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] ...
public void strokeRoundRectangle(Rectangle rect, Color color, float linewidth, float r) { template.saveState(); setStroke(color, linewidth, null); template.roundRectangle(origX + rect.getLeft(), origY + rect.getBottom(), rect.getWidth(), rect.getHeight(), r); template.stroke(); template.restoreState(); }
class class_name[name] begin[{] method[strokeRoundRectangle, return_type[void], modifier[public], parameter[rect, color, linewidth, r]] begin[{] call[template.saveState, parameter[]] call[.setStroke, parameter[member[.color], member[.linewidth], literal[null]]] c...
Keyword[public] Keyword[void] identifier[strokeRoundRectangle] operator[SEP] identifier[Rectangle] identifier[rect] , identifier[Color] identifier[color] , Keyword[float] identifier[linewidth] , Keyword[float] identifier[r] operator[SEP] { identifier[template] operator[SEP] identifier[saveState] operator[SEP]...
protected Module addSerializer(SimpleModule module) { module.addSerializer(ConfigModel.class, Holder.CONFIG_MODEL_SERIALIZER); module.addSerializer(Config.class, Holder.CONFIG_SERIALIZER); module.addSerializer(Json.RawValue.class, Holder.RAW_VALUE_SERIALIZER); return module; }
class class_name[name] begin[{] method[addSerializer, return_type[type[Module]], modifier[protected], parameter[module]] begin[{] call[module.addSerializer, parameter[ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type=ReferenceType(arguments=None, dimension...
Keyword[protected] identifier[Module] identifier[addSerializer] operator[SEP] identifier[SimpleModule] identifier[module] operator[SEP] { identifier[module] operator[SEP] identifier[addSerializer] operator[SEP] identifier[ConfigModel] operator[SEP] Keyword[class] , identifier[Holder] operator[SEP] identifier[CO...
public static java.sql.Date toSqlDate(String monthStr, String dayStr, String yearStr) { java.util.Date newDate = toDate(monthStr, dayStr, yearStr, "0", "0", "0"); if (newDate != null) return new java.sql.Date(newDate.getTime()); else return null; }
class class_name[name] begin[{] method[toSqlDate, return_type[type[java]], modifier[public static], parameter[monthStr, dayStr, yearStr]] begin[{] local_variable[type[java], newDate] if[binary_operation[member[.newDate], !=, literal[null]]] begin[{] return[ClassCreator(arguments=[Method...
Keyword[public] Keyword[static] identifier[java] operator[SEP] identifier[sql] operator[SEP] identifier[Date] identifier[toSqlDate] operator[SEP] identifier[String] identifier[monthStr] , identifier[String] identifier[dayStr] , identifier[String] identifier[yearStr] operator[SEP] { identifier[java] operator[SE...
private EmbeddedNeo4jConfiguration getEmbeddedNeo4jConfiguration() { OptionHelper.verifyDeprecatedOption(PARAMETER_SERVER_ADDRESS, this.serverAddress, PARAMETER_EMBEDDED_LISTEN_ADDRESS); OptionHelper.verifyDeprecatedOption(PARAMETER_SERVER_PORT, this.serverPort, PARAMETER_EMBEDDED_HTTP_PORT); Em...
class class_name[name] begin[{] method[getEmbeddedNeo4jConfiguration, return_type[type[EmbeddedNeo4jConfiguration]], modifier[private], parameter[]] begin[{] call[OptionHelper.verifyDeprecatedOption, parameter[member[.PARAMETER_SERVER_ADDRESS], THIS[member[None.serverAddress]], member[.PARAMETE...
Keyword[private] identifier[EmbeddedNeo4jConfiguration] identifier[getEmbeddedNeo4jConfiguration] operator[SEP] operator[SEP] { identifier[OptionHelper] operator[SEP] identifier[verifyDeprecatedOption] operator[SEP] identifier[PARAMETER_SERVER_ADDRESS] , Keyword[this] operator[SEP] identifier[serverAddress] , ...
public List<ThriftRow> toIndexThriftRow(Object e, EntityMetadata m, String columnFamily) { List<ThriftRow> indexThriftRows = new ArrayList<ThriftRow>(); byte[] rowKey = getThriftColumnValue(e, m.getIdAttribute()); MetamodelImpl metaModel = (MetamodelImpl) kunderaMetadata.getApplicationMeta...
class class_name[name] begin[{] method[toIndexThriftRow, return_type[type[List]], modifier[public], parameter[e, m, columnFamily]] begin[{] local_variable[type[List], indexThriftRows] local_variable[type[byte], rowKey] local_variable[type[MetamodelImpl], metaModel] local_variabl...
Keyword[public] identifier[List] operator[<] identifier[ThriftRow] operator[>] identifier[toIndexThriftRow] operator[SEP] identifier[Object] identifier[e] , identifier[EntityMetadata] identifier[m] , identifier[String] identifier[columnFamily] operator[SEP] { identifier[List] operator[<] identifier[ThriftRow] ...
protected ArrayList<EnvLoaderListener> getEnvironmentListeners() { ArrayList<EnvLoaderListener> listeners; listeners = new ArrayList<EnvLoaderListener>(); /* // add the descendant listeners if (_childListeners != null) { synchronized (_childListenerLock) { ClassLoader loader; ...
class class_name[name] begin[{] method[getEnvironmentListeners, return_type[type[ArrayList]], modifier[protected], parameter[]] begin[{] local_variable[type[ArrayList], listeners] assign[member[.listeners], ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_o...
Keyword[protected] identifier[ArrayList] operator[<] identifier[EnvLoaderListener] operator[>] identifier[getEnvironmentListeners] operator[SEP] operator[SEP] { identifier[ArrayList] operator[<] identifier[EnvLoaderListener] operator[>] identifier[listeners] operator[SEP] identifier[listeners] operator[=] Keywor...
@Override public EntityManager createEntityManager() { if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) Tr.debug(tc, "createEntityManager : " + this); EntityManager em = getEntityManager(false, false); JPAPooledEntityManager pem = new JPAPooledEntityManager(t...
class class_name[name] begin[{] method[createEntityManager, return_type[type[EntityManager]], modifier[public], parameter[]] begin[{] if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isDebugEnabled, parameter[]]]] begin[{] call[Tr.debug, paramet...
annotation[@] identifier[Override] Keyword[public] identifier[EntityManager] identifier[createEntityManager] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identifier[tc] operator[SEP] ident...
private List<ResolveTask> removeDuplicateResolveTargets(List<ResolveTask> renames) { return renames.stream() .collect(Collectors.groupingBy( rt -> rt.scope, Collectors.toMap( rt -> rt.in.uri, ...
class class_name[name] begin[{] method[removeDuplicateResolveTargets, return_type[type[List]], modifier[private], parameter[renames]] begin[{] return[call[renames.stream, parameter[]]] end[}] END[}]
Keyword[private] identifier[List] operator[<] identifier[ResolveTask] operator[>] identifier[removeDuplicateResolveTargets] operator[SEP] identifier[List] operator[<] identifier[ResolveTask] operator[>] identifier[renames] operator[SEP] { Keyword[return] identifier[renames] operator[SEP] identifier[stream] opera...
@Override public <T> List<Object> getAllCacheKeys(final Class<T> clazz) { try { return getObjectPersister(clazz).getAllCacheKeys(); } catch (CacheCreationException e) { Ln.e(e); return Collections.emptyList(); } }
class class_name[name] begin[{] method[getAllCacheKeys, return_type[type[List]], modifier[public], parameter[clazz]] begin[{] TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[MemberReference(member=clazz, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], m...
annotation[@] identifier[Override] Keyword[public] operator[<] identifier[T] operator[>] identifier[List] operator[<] identifier[Object] operator[>] identifier[getAllCacheKeys] operator[SEP] Keyword[final] identifier[Class] operator[<] identifier[T] operator[>] identifier[clazz] operator[SEP] { Keyword[try] { ...
@Override @Scope(DocScope.IO) public <T> T projectXMLString(final String xmlContent, final Class<T> projectionInterface) { try { final ByteArrayInputStream inputStream = new ByteArrayInputStream(xmlContent.getBytes("utf-8")); return new StreamInput(this, inputStream).read(project...
class class_name[name] begin[{] method[projectXMLString, return_type[type[T]], modifier[public], parameter[xmlContent, projectionInterface]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=ClassCreator(arguments=[MethodInv...
annotation[@] identifier[Override] annotation[@] identifier[Scope] operator[SEP] identifier[DocScope] operator[SEP] identifier[IO] operator[SEP] Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[projectXMLString] operator[SEP] Keyword[final] identifier[String] identifier[xmlContent] , Keyw...
public static LinkedHashMap<String, Type> track(final Class<?> type, final Class<?> known, final LinkedHashMap<String, Type> knownGenerics) { if (type.getTypeParameters().length == 0 || knownGenerics.isEmpty(...
class class_name[name] begin[{] method[track, return_type[type[LinkedHashMap]], modifier[public static], parameter[type, known, knownGenerics]] begin[{] if[binary_operation[binary_operation[call[type.getTypeParameters, parameter[]], ==, literal[0]], ||, call[knownGenerics.isEmpty, parameter[]]]...
Keyword[public] Keyword[static] identifier[LinkedHashMap] operator[<] identifier[String] , identifier[Type] operator[>] identifier[track] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifier[type] , Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifie...
public static ImageBuffer applyMask(ImageBuffer imageBuffer, ColorRgba maskColor) { return factoryGraphic.applyMask(imageBuffer, maskColor); }
class class_name[name] begin[{] method[applyMask, return_type[type[ImageBuffer]], modifier[public static], parameter[imageBuffer, maskColor]] begin[{] return[call[factoryGraphic.applyMask, parameter[member[.imageBuffer], member[.maskColor]]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[ImageBuffer] identifier[applyMask] operator[SEP] identifier[ImageBuffer] identifier[imageBuffer] , identifier[ColorRgba] identifier[maskColor] operator[SEP] { Keyword[return] identifier[factoryGraphic] operator[SEP] identifier[applyMask] operator[SEP] identifier[imageB...
private void addTrafficSource() { VectorSource trafficSource = new VectorSource(TrafficData.SOURCE_ID, TrafficData.SOURCE_URL); style.addSource(trafficSource); }
class class_name[name] begin[{] method[addTrafficSource, return_type[void], modifier[private], parameter[]] begin[{] local_variable[type[VectorSource], trafficSource] call[style.addSource, parameter[member[.trafficSource]]] end[}] END[}]
Keyword[private] Keyword[void] identifier[addTrafficSource] operator[SEP] operator[SEP] { identifier[VectorSource] identifier[trafficSource] operator[=] Keyword[new] identifier[VectorSource] operator[SEP] identifier[TrafficData] operator[SEP] identifier[SOURCE_ID] , identifier[TrafficData] operator[SEP] identif...
public void attach(M m, Evaluation eval) { _evaluations[m.ordinal()] = _evaluations[m.ordinal()] == null ? eval : new CompoundMilestoneEvaluation(eval, _evaluations[m.ordinal()]); }
class class_name[name] begin[{] method[attach, return_type[void], modifier[public], parameter[m, eval]] begin[{] assign[member[._evaluations], TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=_evaluations, postfix_operators=[], prefix_operators=[], qualifier=, selecto...
Keyword[public] Keyword[void] identifier[attach] operator[SEP] identifier[M] identifier[m] , identifier[Evaluation] identifier[eval] operator[SEP] { identifier[_evaluations] operator[SEP] identifier[m] operator[SEP] identifier[ordinal] operator[SEP] operator[SEP] operator[SEP] operator[=] identifier[_evaluation...
public static String random(int count, int start, int end, final boolean letters, final boolean numbers, final char[] chars, final Random random) { if (count == 0) { return StringUtils.EMPTY; } else if (count < 0) { throw new IllegalArgumentEx...
class class_name[name] begin[{] method[random, return_type[type[String]], modifier[public static], parameter[count, start, end, letters, numbers, chars, random]] begin[{] if[binary_operation[member[.count], ==, literal[0]]] begin[{] return[member[StringUtils.EMPTY]] else beg...
Keyword[public] Keyword[static] identifier[String] identifier[random] operator[SEP] Keyword[int] identifier[count] , Keyword[int] identifier[start] , Keyword[int] identifier[end] , Keyword[final] Keyword[boolean] identifier[letters] , Keyword[final] Keyword[boolean] identifier[numbers] , Keyword[final] Keyword[cha...
@Override public String resolve( String mid, Features features, Set<String> dependentFeatures, StringBuffer sb, boolean resolveAliases) { return resolve(mid, features, dependentFeatures, sb, resolveAliases, true); }
class class_name[name] begin[{] method[resolve, return_type[type[String]], modifier[public], parameter[mid, features, dependentFeatures, sb, resolveAliases]] begin[{] return[call[.resolve, parameter[member[.mid], member[.features], member[.dependentFeatures], member[.sb], member[.resolveAliases], liter...
annotation[@] identifier[Override] Keyword[public] identifier[String] identifier[resolve] operator[SEP] identifier[String] identifier[mid] , identifier[Features] identifier[features] , identifier[Set] operator[<] identifier[String] operator[>] identifier[dependentFeatures] , identifier[StringBuffer] identifier[sb] ,...
private void initializeBeanMethodTransactionAttributes(boolean isEntity, boolean addRemove, MethodInterface methodInterface, Method[] ejbMethod...
class class_name[name] begin[{] method[initializeBeanMethodTransactionAttributes, return_type[void], modifier[private], parameter[isEntity, addRemove, methodInterface, ejbMethods, entityNoTxAttrMethods, entityNoTxAttrMethodSignatures, transactionList, activitySessionList, methodNames, methodParamTypes, methodS...
Keyword[private] Keyword[void] identifier[initializeBeanMethodTransactionAttributes] operator[SEP] Keyword[boolean] identifier[isEntity] , Keyword[boolean] identifier[addRemove] , identifier[MethodInterface] identifier[methodInterface] , identifier[Method] operator[SEP] operator[SEP] identifier[ejbMethods] , identi...
public void remove(@NonNull String viewId) { if (viewId == null) { throw new NullPointerException("View Id is null"); } presenterMap.remove(viewId); }
class class_name[name] begin[{] method[remove, return_type[void], modifier[public], parameter[viewId]] begin[{] if[binary_operation[member[.viewId], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qual...
Keyword[public] Keyword[void] identifier[remove] operator[SEP] annotation[@] identifier[NonNull] identifier[String] identifier[viewId] operator[SEP] { Keyword[if] operator[SEP] identifier[viewId] operator[==] Other[null] operator[SEP] { Keyword[throw] Keyword[new] identifier[NullPointerException] oper...
@Override public <I> MatchResult<I> matchResult(I item) { StringDescription mismatch = new StringDescription(); if (matches(item, mismatch)) { return new MatchResultSuccess<>(item, this); } else { return new MatchResultMismatch<>(item, this, mismatch.toString())...
class class_name[name] begin[{] method[matchResult, return_type[type[MatchResult]], modifier[public], parameter[item]] begin[{] local_variable[type[StringDescription], mismatch] if[call[.matches, parameter[member[.item], member[.mismatch]]]] begin[{] return[ClassCreator(argu...
annotation[@] identifier[Override] Keyword[public] operator[<] identifier[I] operator[>] identifier[MatchResult] operator[<] identifier[I] operator[>] identifier[matchResult] operator[SEP] identifier[I] identifier[item] operator[SEP] { identifier[StringDescription] identifier[mismatch] operator[=] Keyword[new] i...
@Override public Map<Integer, byte[]> traverseStreamGraphAndGenerateHashes(StreamGraph streamGraph) { // The hash function used to generate the hash final HashFunction hashFunction = Hashing.murmur3_128(0); final Map<Integer, byte[]> hashes = new HashMap<>(); Set<Integer> visited = new HashSet<>(); Queue<St...
class class_name[name] begin[{] method[traverseStreamGraphAndGenerateHashes, return_type[type[Map]], modifier[public], parameter[streamGraph]] begin[{] local_variable[type[HashFunction], hashFunction] local_variable[type[Map], hashes] local_variable[type[Set], visited] local_var...
annotation[@] identifier[Override] Keyword[public] identifier[Map] operator[<] identifier[Integer] , Keyword[byte] operator[SEP] operator[SEP] operator[>] identifier[traverseStreamGraphAndGenerateHashes] operator[SEP] identifier[StreamGraph] identifier[streamGraph] operator[SEP] { Keyword[final] identifier[Hash...
public StructuredQueryDefinition geospatial(GeospatialIndex index, FragmentScope scope, String[] options, Region... regions) { checkRegions(regions); return new GeospatialPointQuery(index, scope, regions, options); }
class class_name[name] begin[{] method[geospatial, return_type[type[StructuredQueryDefinition]], modifier[public], parameter[index, scope, options, regions]] begin[{] call[.checkRegions, parameter[member[.regions]]] return[ClassCreator(arguments=[MemberReference(member=index, postfix_op...
Keyword[public] identifier[StructuredQueryDefinition] identifier[geospatial] operator[SEP] identifier[GeospatialIndex] identifier[index] , identifier[FragmentScope] identifier[scope] , identifier[String] operator[SEP] operator[SEP] identifier[options] , identifier[Region] operator[...] identifier[regions] operator[S...
@Override public boolean isConstant(String name) { if (name.length() <= 1) { return false; } // In compiled code, '$' is often a namespace delimiter. To allow inlining // of namespaced constants, we strip off any namespaces here. int pos = name.lastIndexOf('$'); if (pos >= 0) { na...
class class_name[name] begin[{] method[isConstant, return_type[type[boolean]], modifier[public], parameter[name]] begin[{] if[binary_operation[call[name.length, parameter[]], <=, literal[1]]] begin[{] return[literal[false]] else begin[{] None end[}] local_var...
annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[isConstant] operator[SEP] identifier[String] identifier[name] operator[SEP] { Keyword[if] operator[SEP] identifier[name] operator[SEP] identifier[length] operator[SEP] operator[SEP] operator[<=] Other[1] operator[SEP] { Key...
public Node createProxyNode(Object sourceNodeId, Object targetNodeId, GraphDatabaseService graphDb, EntityMetadata sourceEntityMetadata, EntityMetadata targetEntityMetadata) { String sourceNodeIdColumnName = ((AbstractAttribute) sourceEntityMetadata.getIdAttribute()).getJPAColumnName(); ...
class class_name[name] begin[{] method[createProxyNode, return_type[type[Node]], modifier[public], parameter[sourceNodeId, targetNodeId, graphDb, sourceEntityMetadata, targetEntityMetadata]] begin[{] local_variable[type[String], sourceNodeIdColumnName] local_variable[type[String], targetNodeIdC...
Keyword[public] identifier[Node] identifier[createProxyNode] operator[SEP] identifier[Object] identifier[sourceNodeId] , identifier[Object] identifier[targetNodeId] , identifier[GraphDatabaseService] identifier[graphDb] , identifier[EntityMetadata] identifier[sourceEntityMetadata] , identifier[EntityMetadata] ident...
public String joinWith(String separator, Object... join) { return Joiner.on(separator).join(delegate.get(), EMPTY, join); }
class class_name[name] begin[{] method[joinWith, return_type[type[String]], modifier[public], parameter[separator, join]] begin[{] return[call[Joiner.on, parameter[member[.separator]]]] end[}] END[}]
Keyword[public] identifier[String] identifier[joinWith] operator[SEP] identifier[String] identifier[separator] , identifier[Object] operator[...] identifier[join] operator[SEP] { Keyword[return] identifier[Joiner] operator[SEP] identifier[on] operator[SEP] identifier[separator] operator[SEP] operator[SEP] ident...
public void encodeBuffer(ByteBuffer aBuffer, OutputStream aStream) throws IOException { byte [] buf = getBytes(aBuffer); encodeBuffer(buf, aStream); }
class class_name[name] begin[{] method[encodeBuffer, return_type[void], modifier[public], parameter[aBuffer, aStream]] begin[{] local_variable[type[byte], buf] call[.encodeBuffer, parameter[member[.buf], member[.aStream]]] end[}] END[}]
Keyword[public] Keyword[void] identifier[encodeBuffer] operator[SEP] identifier[ByteBuffer] identifier[aBuffer] , identifier[OutputStream] identifier[aStream] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[byte] operator[SEP] operator[SEP] identifier[buf] operator[=] identifier[getBytes] operat...
@NotNull @ObjectiveCName("bindFileWithReference:autoStart:withCallback:") public FileVM bindFile(FileReference fileReference, boolean isAutoStart, FileVMCallback callback) { return new FileVM(fileReference, isAutoStart, modules, callback); }
class class_name[name] begin[{] method[bindFile, return_type[type[FileVM]], modifier[public], parameter[fileReference, isAutoStart, callback]] begin[{] return[ClassCreator(arguments=[MemberReference(member=fileReference, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberRefere...
annotation[@] identifier[NotNull] annotation[@] identifier[ObjectiveCName] operator[SEP] literal[String] operator[SEP] Keyword[public] identifier[FileVM] identifier[bindFile] operator[SEP] identifier[FileReference] identifier[fileReference] , Keyword[boolean] identifier[isAutoStart] , identifier[FileVMCallback] ident...
protected static List<UnicodeCandidate> getUnicodeCandidates(String input) { char[] inputCharArray = input.toCharArray(); List<UnicodeCandidate> candidates = new ArrayList<UnicodeCandidate>(); UnicodeCandidate next; for (int i = 0; (next = getNextUnicodeCandidate(inputCharArray, i)) != null; i = next.ge...
class class_name[name] begin[{] method[getUnicodeCandidates, return_type[type[List]], modifier[static protected], parameter[input]] begin[{] local_variable[type[char], inputCharArray] local_variable[type[List], candidates] local_variable[type[UnicodeCandidate], next] ForStatemen...
Keyword[protected] Keyword[static] identifier[List] operator[<] identifier[UnicodeCandidate] operator[>] identifier[getUnicodeCandidates] operator[SEP] identifier[String] identifier[input] operator[SEP] { Keyword[char] operator[SEP] operator[SEP] identifier[inputCharArray] operator[=] identifier[input] operator[...
public static void writeProcessorOutputToValues( final Object output, final Processor<?, ?> processor, final Values values) { Map<String, String> mapper = processor.getOutputMapperBiMap(); if (mapper == null) { mapper = Collections.emptyMap(); } ...
class class_name[name] begin[{] method[writeProcessorOutputToValues, return_type[void], modifier[public static], parameter[output, processor, values]] begin[{] local_variable[type[Map], mapper] if[binary_operation[member[.mapper], ==, literal[null]]] begin[{] ass...
Keyword[public] Keyword[static] Keyword[void] identifier[writeProcessorOutputToValues] operator[SEP] Keyword[final] identifier[Object] identifier[output] , Keyword[final] identifier[Processor] operator[<] operator[?] , operator[?] operator[>] identifier[processor] , Keyword[final] identifier[Values] identifier[value...
public static com.liferay.commerce.model.CommerceOrder fetchCommerceOrderByUuidAndGroupId( String uuid, long groupId) { return getService().fetchCommerceOrderByUuidAndGroupId(uuid, groupId); }
class class_name[name] begin[{] method[fetchCommerceOrderByUuidAndGroupId, return_type[type[com]], modifier[public static], parameter[uuid, groupId]] begin[{] return[call[.getService, parameter[]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[com] operator[SEP] identifier[liferay] operator[SEP] identifier[commerce] operator[SEP] identifier[model] operator[SEP] identifier[CommerceOrder] identifier[fetchCommerceOrderByUuidAndGroupId] operator[SEP] identifier[String] identifier[uuid] , Keyword[long] identifier[groupI...
DependencyInfo getDependencyInfo() { if (dependencyInfo == null) { dependencyInfo = generateDependencyInfo(); } if (!extraRequires.isEmpty() || !extraProvides.isEmpty()) { dependencyInfo = SimpleDependencyInfo.builder(getName(), getName()) .setProvides(concat(dependencyIn...
class class_name[name] begin[{] method[getDependencyInfo, return_type[type[DependencyInfo]], modifier[default], parameter[]] begin[{] if[binary_operation[member[.dependencyInfo], ==, literal[null]]] begin[{] assign[member[.dependencyInfo], call[.generateDependencyInfo, p...
identifier[DependencyInfo] identifier[getDependencyInfo] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[dependencyInfo] operator[==] Other[null] operator[SEP] { identifier[dependencyInfo] operator[=] identifier[generateDependencyInfo] operator[SEP] operator[SEP] operator[SEP] ...
public void stopThreads() { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } lock.lock(); try { Thread currentThread = Thread.currentThread(); for (Thread thread : threadMap....
class class_name[name] begin[{] method[stopThreads, return_type[void], modifier[public], parameter[]] begin[{] if[call[threadMap.isEmpty, parameter[]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selec...
Keyword[public] Keyword[void] identifier[stopThreads] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[threadMap] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] { Keyword[throw] Keyword[new] identifier[IllegalStateException] operator[SEP] literal[String] ...
protected static String getEndedWord(String str, int pos){ assert(pos < str.length() && pos >= 0); if( posIsAtWordEnd(str, pos) ){ int prevSpace = findLastNonLetterOrDigit(str, pos); return str.substring(prevSpace+1, pos+1); } return null; }
class class_name[name] begin[{] method[getEndedWord, return_type[type[String]], modifier[static protected], parameter[str, pos]] begin[{] AssertStatement(condition=BinaryOperation(operandl=BinaryOperation(operandl=MemberReference(member=pos, postfix_operators=[], prefix_operators=[], qualifier=, select...
Keyword[protected] Keyword[static] identifier[String] identifier[getEndedWord] operator[SEP] identifier[String] identifier[str] , Keyword[int] identifier[pos] operator[SEP] { Keyword[assert] operator[SEP] identifier[pos] operator[<] identifier[str] operator[SEP] identifier[length] operator[SEP] operator[SEP] op...
public String getPageContent() { if(pageConent != null){return pageConent;} pageConent = gpUtil.getPageContent(page); return pageConent; }
class class_name[name] begin[{] method[getPageContent, return_type[type[String]], modifier[public], parameter[]] begin[{] if[binary_operation[member[.pageConent], !=, literal[null]]] begin[{] return[member[.pageConent]] else begin[{] None end[}] assig...
Keyword[public] identifier[String] identifier[getPageContent] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[pageConent] operator[!=] Other[null] operator[SEP] { Keyword[return] identifier[pageConent] operator[SEP] } identifier[pageConent] operator[=] identifier[gpUti...
public static JsonNode getFirstNode(final String text, final String path) { try { JsonNode node = mapper.readValue(text, JsonNode.class); if (path != null) { node = (JsonNode) getElement(node, path); } return node; } catch (final IOExceptio...
class class_name[name] begin[{] method[getFirstNode, return_type[type[JsonNode]], modifier[public static], parameter[text, path]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[MemberReference(...
Keyword[public] Keyword[static] identifier[JsonNode] identifier[getFirstNode] operator[SEP] Keyword[final] identifier[String] identifier[text] , Keyword[final] identifier[String] identifier[path] operator[SEP] { Keyword[try] { identifier[JsonNode] identifier[node] operator[=] identifier[mapper] opera...
public T get(T dest, int index) { checkBounds(index); // We would rather do // UnsafeHelper.copyMemory(null, offset(index), dest, firstFieldOffset, elementSize); // but this is unsupported by the Unsafe class copier.copy(dest, offset(index)); return dest; }
class class_name[name] begin[{] method[get, return_type[type[T]], modifier[public], parameter[dest, index]] begin[{] call[.checkBounds, parameter[member[.index]]] call[copier.copy, parameter[member[.dest], call[.offset, parameter[member[.index]]]]] return[member[.dest]] ...
Keyword[public] identifier[T] identifier[get] operator[SEP] identifier[T] identifier[dest] , Keyword[int] identifier[index] operator[SEP] { identifier[checkBounds] operator[SEP] identifier[index] operator[SEP] operator[SEP] identifier[copier] operator[SEP] identifier[copy] operator[SEP] identifier[dest] , iden...
public void installIfNotInstalled() throws IOException { try { factory.getNodeAndNPMInstaller(proxy()) .install(mojo.getNodeVersion(), mojo.getNPMVersion(), mojo.getNodeDistributionRootUrl(), mojo...
class class_name[name] begin[{] method[installIfNotInstalled, return_type[void], modifier[public], parameter[]] begin[{] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=proxy, postfix_operators=[], prefix_operators=[], qualifier=, sel...
Keyword[public] Keyword[void] identifier[installIfNotInstalled] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[try] { identifier[factory] operator[SEP] identifier[getNodeAndNPMInstaller] operator[SEP] identifier[proxy] operator[SEP] operator[SEP] operator[SEP] operator[S...
public <T extends Named> List<T> prepareProcessors(List<T> namedList, String type) { List<T> ret = new ArrayList<>(); Map<String, T> lookup = new HashMap<>(); for (T named : namedList) { lookup.put(named.getName(), named); } for (String inc : includes) { i...
class class_name[name] begin[{] method[prepareProcessors, return_type[type[List]], modifier[public], parameter[namedList, type]] begin[{] local_variable[type[List], ret] local_variable[type[Map], lookup] ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expres...
Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[Named] operator[>] identifier[List] operator[<] identifier[T] operator[>] identifier[prepareProcessors] operator[SEP] identifier[List] operator[<] identifier[T] operator[>] identifier[namedList] , identifier[String] identifier[type] operator[SEP] {...
private Node createParameters(boolean lastVarArgs, JSType... parameterTypes) { FunctionParamBuilder builder = new FunctionParamBuilder(this); int max = parameterTypes.length - 1; for (int i = 0; i <= max; i++) { if (lastVarArgs && i == max) { builder.addVarArgs(parameterTypes[i]); } else...
class class_name[name] begin[{] method[createParameters, return_type[type[Node]], modifier[private], parameter[lastVarArgs, parameterTypes]] begin[{] local_variable[type[FunctionParamBuilder], builder] local_variable[type[int], max] ForStatement(body=BlockStatement(label=None, statement...
Keyword[private] identifier[Node] identifier[createParameters] operator[SEP] Keyword[boolean] identifier[lastVarArgs] , identifier[JSType] operator[...] identifier[parameterTypes] operator[SEP] { identifier[FunctionParamBuilder] identifier[builder] operator[=] Keyword[new] identifier[FunctionParamBuilder] opera...
@Override public synchronized void mark(int idx) throws IOException { try { in.mark(idx); } catch (IOException e) { handleIOException(e); } }
class class_name[name] begin[{] method[mark, return_type[void], modifier[synchronized public], parameter[idx]] begin[{] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=idx, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], membe...
annotation[@] identifier[Override] Keyword[public] Keyword[synchronized] Keyword[void] identifier[mark] operator[SEP] Keyword[int] identifier[idx] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[try] { identifier[in] operator[SEP] identifier[mark] operator[SEP] identifier[idx] operator...
public final void entryRuleRuleID() throws RecognitionException { try { // InternalXtext.g:796:1: ( ruleRuleID EOF ) // InternalXtext.g:797:1: ruleRuleID EOF { before(grammarAccess.getRuleIDRule()); pushFollow(FollowSets000.FOLLOW_1); rul...
class class_name[name] begin[{] method[entryRuleRuleID, return_type[void], modifier[final public], parameter[]] begin[{] TryStatement(block=[BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=getRuleIDRule, postfix_ope...
Keyword[public] Keyword[final] Keyword[void] identifier[entryRuleRuleID] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] { Keyword[try] { { identifier[before] operator[SEP] identifier[grammarAccess] operator[SEP] identifier[getRuleIDRule] operator[SEP] opera...
public static List<Polygon> gridcoverageToCellPolygons( GridCoverage2D coverage ) { RegionMap regionMap = CoverageUtilities.getRegionParamsFromGridCoverage(coverage); double west = regionMap.getWest(); double north = regionMap.getNorth(); double xres = regionMap.getXres(); double...
class class_name[name] begin[{] method[gridcoverageToCellPolygons, return_type[type[List]], modifier[public static], parameter[coverage]] begin[{] local_variable[type[RegionMap], regionMap] local_variable[type[double], west] local_variable[type[double], north] local_variable[typ...
Keyword[public] Keyword[static] identifier[List] operator[<] identifier[Polygon] operator[>] identifier[gridcoverageToCellPolygons] operator[SEP] identifier[GridCoverage2D] identifier[coverage] operator[SEP] { identifier[RegionMap] identifier[regionMap] operator[=] identifier[CoverageUtilities] operator[SEP] ide...
public WebApp registerComponent(final Class<?> madvocComponent) { Objects.requireNonNull(madvocComponent); madvocComponents.add(ClassConsumer.of(madvocComponent)); return this; }
class class_name[name] begin[{] method[registerComponent, return_type[type[WebApp]], modifier[public], parameter[madvocComponent]] begin[{] call[Objects.requireNonNull, parameter[member[.madvocComponent]]] call[madvocComponents.add, parameter[call[ClassConsumer.of, parameter[mem...
Keyword[public] identifier[WebApp] identifier[registerComponent] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifier[madvocComponent] operator[SEP] { identifier[Objects] operator[SEP] identifier[requireNonNull] operator[SEP] identifier[madvocComponent] operator[SEP] oper...
public static <T> T assertNotNull(T object, String message, Object... args) { return assertNotNull(object, null, message, args); }
class class_name[name] begin[{] method[assertNotNull, return_type[type[T]], modifier[public static], parameter[object, message, args]] begin[{] return[call[.assertNotNull, parameter[member[.object], literal[null], member[.message], member[.args]]]] end[}] END[}]
Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[T] identifier[assertNotNull] operator[SEP] identifier[T] identifier[object] , identifier[String] identifier[message] , identifier[Object] operator[...] identifier[args] operator[SEP] { Keyword[return] identifier[assertNotNull] ope...
void copyToLocal(String[]argv, int pos) throws IOException { CommandFormat cf = new CommandFormat("copyToLocal", 2,2,"crc","ignoreCrc"); String srcstr = null; String dststr = null; try { List<String> parameters = cf.parse(argv, pos); srcstr = parameters.get(0); dststr = parameters...
class class_name[name] begin[{] method[copyToLocal, return_type[void], modifier[default], parameter[argv, pos]] begin[{] local_variable[type[CommandFormat], cf] local_variable[type[String], srcstr] local_variable[type[String], dststr] TryStatement(block=[LocalVariableDeclaration...
Keyword[void] identifier[copyToLocal] operator[SEP] identifier[String] operator[SEP] operator[SEP] identifier[argv] , Keyword[int] identifier[pos] operator[SEP] Keyword[throws] identifier[IOException] { identifier[CommandFormat] identifier[cf] operator[=] Keyword[new] identifier[CommandFormat] operator[SEP] lit...
public String toShortString() { StringBuilder sb = new StringBuilder(); taskToString(sb); if (m_msg != null) { sb.append("\n"); m_msg.toShortString(sb); } return sb.toString(); }
class class_name[name] begin[{] method[toShortString, return_type[type[String]], modifier[public], parameter[]] begin[{] local_variable[type[StringBuilder], sb] call[.taskToString, parameter[member[.sb]]] if[binary_operation[member[.m_msg], !=, literal[null]]] begin[{] ...
Keyword[public] identifier[String] identifier[toShortString] operator[SEP] operator[SEP] { identifier[StringBuilder] identifier[sb] operator[=] Keyword[new] identifier[StringBuilder] operator[SEP] operator[SEP] operator[SEP] identifier[taskToString] operator[SEP] identifier[sb] operator[SEP] operator[SEP] Keywor...