code
stringlengths
63
466k
code_sememe
stringlengths
141
3.79M
token_type
stringlengths
274
1.23M
public static ClientBean unmarshallClient(Map<String, Object> source) { if (source == null) { return null; } ClientBean bean = new ClientBean(); bean.setId(asString(source.get("id"))); bean.setName(asString(source.get("name"))); bean.setDescription(asString(so...
class class_name[name] begin[{] method[unmarshallClient, return_type[type[ClientBean]], modifier[public static], parameter[source]] begin[{] if[binary_operation[member[.source], ==, literal[null]]] begin[{] return[literal[null]] else begin[{] None end[}] loca...
Keyword[public] Keyword[static] identifier[ClientBean] identifier[unmarshallClient] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[source] operator[SEP] { Keyword[if] operator[SEP] identifier[source] operator[==] Other[null] operator[SEP] { Ke...
public static base_responses add(nitro_service client, cachecontentgroup resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cachecontentgroup addresources[] = new cachecontentgroup[resources.length]; for (int i=0;i<resources.length;i++){ addresou...
class class_name[name] begin[{] method[add, return_type[type[base_responses]], modifier[public static], parameter[client, resources]] begin[{] local_variable[type[base_responses], result] if[binary_operation[binary_operation[member[.resources], !=, literal[null]], &&, binary_operation[m...
Keyword[public] Keyword[static] identifier[base_responses] identifier[add] operator[SEP] identifier[nitro_service] identifier[client] , identifier[cachecontentgroup] identifier[resources] operator[SEP] operator[SEP] operator[SEP] Keyword[throws] identifier[Exception] { identifier[base_responses] identifier[resu...
static void generateVisitors(Set<String> elementNames, List<XsdAttribute> attributes, String apiName){ generateVisitorInterface(elementNames, filterAttributes(attributes), apiName); }
class class_name[name] begin[{] method[generateVisitors, return_type[void], modifier[static], parameter[elementNames, attributes, apiName]] begin[{] call[.generateVisitorInterface, parameter[member[.elementNames], call[.filterAttributes, parameter[member[.attributes]]], member[.apiName]]] e...
Keyword[static] Keyword[void] identifier[generateVisitors] operator[SEP] identifier[Set] operator[<] identifier[String] operator[>] identifier[elementNames] , identifier[List] operator[<] identifier[XsdAttribute] operator[>] identifier[attributes] , identifier[String] identifier[apiName] operator[SEP] { identi...
public static Feed buildFeed(FeedDesc feedDesc){ Feed feed = null; NitFactory nitFactory = new NitFactory(); NitDesc nitDesc = nitDescFromDynamic(feedDesc); nitDesc.setConstructorParameters(new Class [] { Map.class }); nitDesc.setConstructorArguments(new Object[] { feedDesc.getProperties() }); t...
class class_name[name] begin[{] method[buildFeed, return_type[type[Feed]], modifier[public static], parameter[feedDesc]] begin[{] local_variable[type[Feed], feed] local_variable[type[NitFactory], nitFactory] local_variable[type[NitDesc], nitDesc] call[nitDesc.setConstruc...
Keyword[public] Keyword[static] identifier[Feed] identifier[buildFeed] operator[SEP] identifier[FeedDesc] identifier[feedDesc] operator[SEP] { identifier[Feed] identifier[feed] operator[=] Other[null] operator[SEP] identifier[NitFactory] identifier[nitFactory] operator[=] Keyword[new] identifier[NitFactory] oper...
@Pure public static <P1, P2> Procedure1<P2> curry(final Procedure2<? super P1, ? super P2> procedure, final P1 argument) { if (procedure == null) throw new NullPointerException("procedure"); return new Procedure1<P2>() { @Override public void apply(P2 p) { procedure.apply(argument, p); } }; }
class class_name[name] begin[{] method[curry, return_type[type[Procedure1]], modifier[public static], parameter[procedure, argument]] begin[{] if[binary_operation[member[.procedure], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], pre...
annotation[@] identifier[Pure] Keyword[public] Keyword[static] operator[<] identifier[P1] , identifier[P2] operator[>] identifier[Procedure1] operator[<] identifier[P2] operator[>] identifier[curry] operator[SEP] Keyword[final] identifier[Procedure2] operator[<] operator[?] Keyword[super] identifier[P1] , operator[?]...
public long raw_total(int i){ if(!seekable||i>=links) return (-1); if(i<0){ long acc=0; // bug? for(int j=0; j<links; j++){ acc+=raw_total(j); } return (acc); } else{ return (offsets[i+1]-offsets[i]); } }
class class_name[name] begin[{] method[raw_total, return_type[type[long]], modifier[public], parameter[i]] begin[{] if[binary_operation[member[.seekable], ||, binary_operation[member[.i], >=, member[.links]]]] begin[{] return[literal[1]] else begin[{] None end[}] ...
Keyword[public] Keyword[long] identifier[raw_total] operator[SEP] Keyword[int] identifier[i] operator[SEP] { Keyword[if] operator[SEP] operator[!] identifier[seekable] operator[||] identifier[i] operator[>=] identifier[links] operator[SEP] Keyword[return] operator[SEP] operator[-] Other[1] operator[SEP] operator...
public void startUp() throws Exception { logger.info(String.format("Starting RPC server on port %d", port)); ServerBootstrap bootstrap = new ServerBootstrap(); ChannelFuture futureChannel = bootstrap.group(parentGroup, childGroup) .channel(channelClass) .childHandler(channelInitializer()) ...
class class_name[name] begin[{] method[startUp, return_type[void], modifier[public], parameter[]] begin[{] call[logger.info, parameter[call[String.format, parameter[literal["Starting RPC server on port %d"], member[.port]]]]] local_variable[type[ServerBootstrap], bootstrap] loca...
Keyword[public] Keyword[void] identifier[startUp] operator[SEP] operator[SEP] Keyword[throws] identifier[Exception] { identifier[logger] operator[SEP] identifier[info] operator[SEP] identifier[String] operator[SEP] identifier[format] operator[SEP] literal[String] , identifier[port] operator[SEP] operator[SEP] o...
public HttpRequest buildPutRequest(GenericUrl url, HttpContent content) throws IOException { return buildRequest(HttpMethods.PUT, url, content); }
class class_name[name] begin[{] method[buildPutRequest, return_type[type[HttpRequest]], modifier[public], parameter[url, content]] begin[{] return[call[.buildRequest, parameter[member[HttpMethods.PUT], member[.url], member[.content]]]] end[}] END[}]
Keyword[public] identifier[HttpRequest] identifier[buildPutRequest] operator[SEP] identifier[GenericUrl] identifier[url] , identifier[HttpContent] identifier[content] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[return] identifier[buildRequest] operator[SEP] identifier[HttpMethods] operator[S...
public void marshall(DeleteUserPoolClientRequest deleteUserPoolClientRequest, ProtocolMarshaller protocolMarshaller) { if (deleteUserPoolClientRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshal...
class class_name[name] begin[{] method[marshall, return_type[void], modifier[public], parameter[deleteUserPoolClientRequest, protocolMarshaller]] begin[{] if[binary_operation[member[.deleteUserPoolClientRequest], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(ar...
Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[DeleteUserPoolClientRequest] identifier[deleteUserPoolClientRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] { Keyword[if] operator[SEP] identifier[deleteUserPoolClientRequest] operator[==] Other[nu...
boolean addCode(int code, byte []minKey, byte []maxKey, int pid) { int len = minKey.length + maxKey.length + 5; int index = getIndex() - len; int ptr = index; if (ptr < 0) { return false; } byte []buffer = getBuffer(); buffer[ptr] = (byte) code; ptr += 1;...
class class_name[name] begin[{] method[addCode, return_type[type[boolean]], modifier[default], parameter[code, minKey, maxKey, pid]] begin[{] local_variable[type[int], len] local_variable[type[int], index] local_variable[type[int], ptr] if[binary_operation[member[.ptr], ...
Keyword[boolean] identifier[addCode] operator[SEP] Keyword[int] identifier[code] , Keyword[byte] operator[SEP] operator[SEP] identifier[minKey] , Keyword[byte] operator[SEP] operator[SEP] identifier[maxKey] , Keyword[int] identifier[pid] operator[SEP] { Keyword[int] identifier[len] operator[=] identifier[minK...
public static void handleThemeResourceRequest(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException { if (req.getHeader("If-Modified-Since") != null) { resp.reset(); resp.setStatus(HttpServletResponse.SC_NOT_MODIFIED); return; } String fileName = req.g...
class class_name[name] begin[{] method[handleThemeResourceRequest, return_type[void], modifier[public static], parameter[req, resp]] begin[{] if[binary_operation[call[req.getHeader, parameter[literal["If-Modified-Since"]]], !=, literal[null]]] begin[{] call[resp.reset, p...
Keyword[public] Keyword[static] Keyword[void] identifier[handleThemeResourceRequest] operator[SEP] Keyword[final] identifier[HttpServletRequest] identifier[req] , Keyword[final] identifier[HttpServletResponse] identifier[resp] operator[SEP] Keyword[throws] identifier[ServletException] , identifier[IOException] { ...
private static LoginContext createLoginContext(AuthType authType, Subject subject, ClassLoader classLoader, javax.security.auth.login.Configuration configuration, AlluxioConfiguration alluxioConf) throws LoginException { CallbackHandler callbackHandler = null; if (authType.equals(AuthType.SIMP...
class class_name[name] begin[{] method[createLoginContext, return_type[type[LoginContext]], modifier[private static], parameter[authType, subject, classLoader, configuration, alluxioConf]] begin[{] local_variable[type[CallbackHandler], callbackHandler] if[binary_operation[call[authType....
Keyword[private] Keyword[static] identifier[LoginContext] identifier[createLoginContext] operator[SEP] identifier[AuthType] identifier[authType] , identifier[Subject] identifier[subject] , identifier[ClassLoader] identifier[classLoader] , identifier[javax] operator[SEP] identifier[security] operator[SEP] identifier[...
public void eFeature1Init(int y, int yp, Map fmap) { eFeature1Init(y, yp); strId2IdxAdd(fmap); }
class class_name[name] begin[{] method[eFeature1Init, return_type[void], modifier[public], parameter[y, yp, fmap]] begin[{] call[.eFeature1Init, parameter[member[.y], member[.yp]]] call[.strId2IdxAdd, parameter[member[.fmap]]] end[}] END[}]
Keyword[public] Keyword[void] identifier[eFeature1Init] operator[SEP] Keyword[int] identifier[y] , Keyword[int] identifier[yp] , identifier[Map] identifier[fmap] operator[SEP] { identifier[eFeature1Init] operator[SEP] identifier[y] , identifier[yp] operator[SEP] operator[SEP] identifier[strId2IdxAdd] operator...
public final B setHeader(CharSequence name, Object value) { requireNonNull(name, "name"); requireNonNull(value, "value"); getOrCreateHeaders().setObject(HttpHeaderNames.of(name), value); return self(); }
class class_name[name] begin[{] method[setHeader, return_type[type[B]], modifier[final public], parameter[name, value]] begin[{] call[.requireNonNull, parameter[member[.name], literal["name"]]] call[.requireNonNull, parameter[member[.value], literal["value"]]] ca...
Keyword[public] Keyword[final] identifier[B] identifier[setHeader] operator[SEP] identifier[CharSequence] identifier[name] , identifier[Object] identifier[value] operator[SEP] { identifier[requireNonNull] operator[SEP] identifier[name] , literal[String] operator[SEP] operator[SEP] identifier[requireNonNull] op...
public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) { XAttributeMap map = null; // restore correct type of attribute map, i.e., check for buffered // implementation, and correctly restore lazy implementation if // this had been used for serialization. boolean lazy = reade...
class class_name[name] begin[{] method[unmarshal, return_type[type[Object]], modifier[public], parameter[reader, context]] begin[{] local_variable[type[XAttributeMap], map] local_variable[type[boolean], lazy] local_variable[type[boolean], buffered] if[member[.lazy]] begi...
Keyword[public] identifier[Object] identifier[unmarshal] operator[SEP] identifier[HierarchicalStreamReader] identifier[reader] , identifier[UnmarshallingContext] identifier[context] operator[SEP] { identifier[XAttributeMap] identifier[map] operator[=] Other[null] operator[SEP] Keyword[boolean] identifier[lazy] ...
public ParamBuilder put(String name, Object value) { params.put(name, value); return this; }
class class_name[name] begin[{] method[put, return_type[type[ParamBuilder]], modifier[public], parameter[name, value]] begin[{] call[params.put, parameter[member[.name], member[.value]]] return[THIS[]] end[}] END[}]
Keyword[public] identifier[ParamBuilder] identifier[put] operator[SEP] identifier[String] identifier[name] , identifier[Object] identifier[value] operator[SEP] { identifier[params] operator[SEP] identifier[put] operator[SEP] identifier[name] , identifier[value] operator[SEP] operator[SEP] Keyword[return] Keywo...
protected AbstractBuffer reset(long offset, long capacity, long maxCapacity) { this.offset = offset; this.capacity = 0; this.initialCapacity = capacity; this.maxCapacity = maxCapacity; capacity(initialCapacity); references.set(0); rewind(); return this; }
class class_name[name] begin[{] method[reset, return_type[type[AbstractBuffer]], modifier[protected], parameter[offset, capacity, maxCapacity]] begin[{] assign[THIS[member[None.offset]], member[.offset]] assign[THIS[member[None.capacity]], literal[0]] assign[THIS...
Keyword[protected] identifier[AbstractBuffer] identifier[reset] operator[SEP] Keyword[long] identifier[offset] , Keyword[long] identifier[capacity] , Keyword[long] identifier[maxCapacity] operator[SEP] { Keyword[this] operator[SEP] identifier[offset] operator[=] identifier[offset] operator[SEP] Keyword[this] o...
public String getInfix(String className) { String postfix = getActionSuffix(); String simpleName = className.substring(className.lastIndexOf('.') + 1); if (Strings.contains(simpleName, postfix)) { simpleName = Strings.uncapitalize(simpleName.substring(0, simpleName.length() - postfix.length())); }...
class class_name[name] begin[{] method[getInfix, return_type[type[String]], modifier[public], parameter[className]] begin[{] local_variable[type[String], postfix] local_variable[type[String], simpleName] if[call[Strings.contains, parameter[member[.simpleName], member[.postfix]]]...
Keyword[public] identifier[String] identifier[getInfix] operator[SEP] identifier[String] identifier[className] operator[SEP] { identifier[String] identifier[postfix] operator[=] identifier[getActionSuffix] operator[SEP] operator[SEP] operator[SEP] identifier[String] identifier[simpleName] operator[=] identifier[...
public static String getFormattedMessage(Class<?> caller, String bundleName, String key, Object[] args, String defaultString) { return TraceNLSResolver.getInstance().getMessage(caller, null, bundleName, key, args, defaultString, true, null, false); }
class class_name[name] begin[{] method[getFormattedMessage, return_type[type[String]], modifier[public static], parameter[caller, bundleName, key, args, defaultString]] begin[{] return[call[TraceNLSResolver.getInstance, parameter[]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[String] identifier[getFormattedMessage] operator[SEP] identifier[Class] operator[<] operator[?] operator[>] identifier[caller] , identifier[String] identifier[bundleName] , identifier[String] identifier[key] , identifier[Object] operator[SEP] operator[SEP] identifier[args] ...
public static synchronized UTEHelper getHelperInstance() throws java.lang.IllegalStateException { if (tcInt.isEntryEnabled()) SibTr.entry(tcInt, "getHelperInstance"); // ************** CHECK TO SEE IF IT IS ENABLED ******************* try { // Initialise the test env flag from...
class class_name[name] begin[{] method[getHelperInstance, return_type[type[UTEHelper]], modifier[synchronized public static], parameter[]] begin[{] if[call[tcInt.isEntryEnabled, parameter[]]] begin[{] call[SibTr.entry, parameter[member[.tcInt], literal["getHelperInstance"]]] ...
Keyword[public] Keyword[static] Keyword[synchronized] identifier[UTEHelper] identifier[getHelperInstance] operator[SEP] operator[SEP] Keyword[throws] identifier[java] operator[SEP] identifier[lang] operator[SEP] identifier[IllegalStateException] { Keyword[if] operator[SEP] identifier[tcInt] operator[SEP] identif...
@Override public void generateReadPropertyFromCursor(Builder methodBuilder, TypeName beanClass, String beanName, ModelProperty property, String cursorName, String indexName) { methodBuilder.addCode(setter(beanClass, beanName, property, "$T.parse$L($L.getBlob($L))"), TypeUtility.mergeTypeNameWithSuffix(beanClass, "Ta...
class class_name[name] begin[{] method[generateReadPropertyFromCursor, return_type[void], modifier[public], parameter[methodBuilder, beanClass, beanName, property, cursorName, indexName]] begin[{] call[methodBuilder.addCode, parameter[call[.setter, parameter[member[.beanClass], member[.beanName...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[generateReadPropertyFromCursor] operator[SEP] identifier[Builder] identifier[methodBuilder] , identifier[TypeName] identifier[beanClass] , identifier[String] identifier[beanName] , identifier[ModelProperty] identifier[property] , identifier...
private long getPreviousSegmentId(File file) { PbdSegmentName segmentName = PbdSegmentName.parseFile(m_usageSpecificLog, file); if (segmentName.m_result != PbdSegmentName.Result.OK) { throw new IllegalStateException("Invalid file name: " + file.getName()); } return segmentNam...
class class_name[name] begin[{] method[getPreviousSegmentId, return_type[type[long]], modifier[private], parameter[file]] begin[{] local_variable[type[PbdSegmentName], segmentName] if[binary_operation[member[segmentName.m_result], !=, member[PbdSegmentName.Result.OK]]] begin[{] ...
Keyword[private] Keyword[long] identifier[getPreviousSegmentId] operator[SEP] identifier[File] identifier[file] operator[SEP] { identifier[PbdSegmentName] identifier[segmentName] operator[=] identifier[PbdSegmentName] operator[SEP] identifier[parseFile] operator[SEP] identifier[m_usageSpecificLog] , identifier[...
@NonNull public static Scene getSceneForLayout(@NonNull ViewGroup sceneRoot, int layoutId, @NonNull Context context) { SparseArray<Scene> scenes = (SparseArray<Scene>) sceneRoot.getTag(R.id.scene_layoutid_cache); if (scenes == null) { scenes = new SparseArray<Scene>(); sceneR...
class class_name[name] begin[{] method[getSceneForLayout, return_type[type[Scene]], modifier[public static], parameter[sceneRoot, layoutId, context]] begin[{] local_variable[type[SparseArray], scenes] if[binary_operation[member[.scenes], ==, literal[null]]] begin[{] ...
annotation[@] identifier[NonNull] Keyword[public] Keyword[static] identifier[Scene] identifier[getSceneForLayout] operator[SEP] annotation[@] identifier[NonNull] identifier[ViewGroup] identifier[sceneRoot] , Keyword[int] identifier[layoutId] , annotation[@] identifier[NonNull] identifier[Context] identifier[context] ...
@Then("^the \"([^\"]*)\" view should contain the element \"([^\"]*)\"$") public WebElement the_view_should_contain(String viewName, String elementName) throws Throwable { return seleniumElementService.viewShouldContainElement(viewName, elementName); }
class class_name[name] begin[{] method[the_view_should_contain, return_type[type[WebElement]], modifier[public], parameter[viewName, elementName]] begin[{] return[call[seleniumElementService.viewShouldContainElement, parameter[member[.viewName], member[.elementName]]]] end[}] END[}]
annotation[@] identifier[Then] operator[SEP] literal[String] operator[SEP] Keyword[public] identifier[WebElement] identifier[the_view_should_contain] operator[SEP] identifier[String] identifier[viewName] , identifier[String] identifier[elementName] operator[SEP] Keyword[throws] identifier[Throwable] { Keyword[r...
protected String makeHeaderNamesLowercaseInLogFormat(String logformat) { // In vim I would simply do: %s@{\([^}]*\)}@{\L\1\E@g // But such an expression is not (yet) possible in Java StringBuffer sb = new StringBuffer(logformat.length()); // All patterns that have a 'name' (note we do N...
class class_name[name] begin[{] method[makeHeaderNamesLowercaseInLogFormat, return_type[type[String]], modifier[protected], parameter[logformat]] begin[{] local_variable[type[StringBuffer], sb] local_variable[type[Pattern], p] local_variable[type[Matcher], m] while[call[...
Keyword[protected] identifier[String] identifier[makeHeaderNamesLowercaseInLogFormat] operator[SEP] identifier[String] identifier[logformat] operator[SEP] { identifier[StringBuffer] identifier[sb] operator[=] Keyword[new] identifier[StringBuffer] operator[SEP] identifier[logformat] operator[SEP] identifier[lengt...
private Map<String, String> getConfigVariables() { return AccessController.doPrivileged(new PrivilegedAction<Map<String, String>>() { @Override public Map<String, String> run() { return configVariables.getUserDefinedVariables(); } }); }
class class_name[name] begin[{] method[getConfigVariables, return_type[type[Map]], modifier[private], parameter[]] begin[{] return[call[AccessController.doPrivileged, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[ReturnStatemen...
Keyword[private] identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[getConfigVariables] operator[SEP] operator[SEP] { Keyword[return] identifier[AccessController] operator[SEP] identifier[doPrivileged] operator[SEP] Keyword[new] identifier[PrivilegedAction] operator[<] id...
public Topic getTopic(String topicId) throws Exception { // [START pubsub_get_topic] try (TopicAdminClient topicAdminClient = TopicAdminClient.create()) { ProjectTopicName topicName = ProjectTopicName.of(projectId, topicId); Topic topic = topicAdminClient.getTopic(topicName); return topic; ...
class class_name[name] begin[{] method[getTopic, return_type[type[Topic]], modifier[public], parameter[topicId]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[MemberReference(member=projectId,...
Keyword[public] identifier[Topic] identifier[getTopic] operator[SEP] identifier[String] identifier[topicId] operator[SEP] Keyword[throws] identifier[Exception] { Keyword[try] operator[SEP] identifier[TopicAdminClient] identifier[topicAdminClient] operator[=] identifier[TopicAdminClient] operator[SEP] identifier[...
@Override public void loadPath(File path, FileFilter filt) { FilePathProcessor.processPath(path, filt, this); }
class class_name[name] begin[{] method[loadPath, return_type[void], modifier[public], parameter[path, filt]] begin[{] call[FilePathProcessor.processPath, parameter[member[.path], member[.filt], THIS[]]] end[}] END[}]
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[loadPath] operator[SEP] identifier[File] identifier[path] , identifier[FileFilter] identifier[filt] operator[SEP] { identifier[FilePathProcessor] operator[SEP] identifier[processPath] operator[SEP] identifier[path] , identifier[filt] ,...
public static CPAttachmentFileEntry fetchByUUID_G(String uuid, long groupId, boolean retrieveFromCache) { return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache); }
class class_name[name] begin[{] method[fetchByUUID_G, return_type[type[CPAttachmentFileEntry]], modifier[public static], parameter[uuid, groupId, retrieveFromCache]] begin[{] return[call[.getPersistence, parameter[]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[CPAttachmentFileEntry] identifier[fetchByUUID_G] operator[SEP] identifier[String] identifier[uuid] , Keyword[long] identifier[groupId] , Keyword[boolean] identifier[retrieveFromCache] operator[SEP] { Keyword[return] identifier[getPersistence] operator[SEP] operator[SE...
public void setReorderingMode(int reorderingMode) { if ((reorderingMode < REORDER_DEFAULT) || (reorderingMode >= REORDER_COUNT)) return; /* don't accept a wrong value */ this.reorderingMode = reorderingMode; this.isInverse = reorderingMode ...
class class_name[name] begin[{] method[setReorderingMode, return_type[void], modifier[public], parameter[reorderingMode]] begin[{] if[binary_operation[binary_operation[member[.reorderingMode], <, member[.REORDER_DEFAULT]], ||, binary_operation[member[.reorderingMode], >=, member[.REORDER_COUNT]...
Keyword[public] Keyword[void] identifier[setReorderingMode] operator[SEP] Keyword[int] identifier[reorderingMode] operator[SEP] { Keyword[if] operator[SEP] operator[SEP] identifier[reorderingMode] operator[<] identifier[REORDER_DEFAULT] operator[SEP] operator[||] operator[SEP] identifier[reorderingMode] operator...
public void setLabel (String label) { _label.setText(label); _label.setVisible(!StringUtil.isBlank(label)); }
class class_name[name] begin[{] method[setLabel, return_type[void], modifier[public], parameter[label]] begin[{] call[_label.setText, parameter[member[.label]]] call[_label.setVisible, parameter[call[StringUtil.isBlank, parameter[member[.label]]]]] end[}] END[}]
Keyword[public] Keyword[void] identifier[setLabel] operator[SEP] identifier[String] identifier[label] operator[SEP] { identifier[_label] operator[SEP] identifier[setText] operator[SEP] identifier[label] operator[SEP] operator[SEP] identifier[_label] operator[SEP] identifier[setVisible] operator[SEP] operator[!] ...
public <T> Set<T> detach(Set<T> pcs) { pm.getFetchPlan().setDetachmentOptions(FetchPlan.DETACH_LOAD_FIELDS); return new LinkedHashSet<>(pm.detachCopyAll(pcs)); }
class class_name[name] begin[{] method[detach, return_type[type[Set]], modifier[public], parameter[pcs]] begin[{] call[pm.getFetchPlan, parameter[]] return[ClassCreator(arguments=[MethodInvocation(arguments=[MemberReference(member=pcs, postfix_operators=[], prefix_operators=[], qualifie...
Keyword[public] operator[<] identifier[T] operator[>] identifier[Set] operator[<] identifier[T] operator[>] identifier[detach] operator[SEP] identifier[Set] operator[<] identifier[T] operator[>] identifier[pcs] operator[SEP] { identifier[pm] operator[SEP] identifier[getFetchPlan] operator[SEP] operator[SEP] oper...
static WSATAsyncResource fromLogData(byte[] bytes) throws javax.transaction.SystemException { if (tc.isEntryEnabled()) Tr.entry(tc, "fromLogData", bytes); WSATAsyncResource resource = null; final ByteArrayInputStream bais = new ByteArrayInputStream(bytes); try {...
class class_name[name] begin[{] method[fromLogData, return_type[type[WSATAsyncResource]], modifier[static], parameter[bytes]] begin[{] if[call[tc.isEntryEnabled, parameter[]]] begin[{] call[Tr.entry, parameter[member[.tc], literal["fromLogData"], member[.bytes]]] else begin[...
Keyword[static] identifier[WSATAsyncResource] identifier[fromLogData] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[bytes] operator[SEP] Keyword[throws] identifier[javax] operator[SEP] identifier[transaction] operator[SEP] identifier[SystemException] { Keyword[if] operator[SEP] identifier[tc...
@Override public DescribeDomainControllersResult describeDomainControllers(DescribeDomainControllersRequest request) { request = beforeClientExecution(request); return executeDescribeDomainControllers(request); }
class class_name[name] begin[{] method[describeDomainControllers, return_type[type[DescribeDomainControllersResult]], modifier[public], parameter[request]] begin[{] assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]] return[call[.executeDescribeDomainCont...
annotation[@] identifier[Override] Keyword[public] identifier[DescribeDomainControllersResult] identifier[describeDomainControllers] operator[SEP] identifier[DescribeDomainControllersRequest] identifier[request] operator[SEP] { identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] ident...
public void setCurrencyAttribute(String name, String value) { ensureAttributes(); Attribute attribute = new CurrencyAttribute(value); attribute.setEditable(isEditable(name)); getAllAttributes().put(name, attribute); }
class class_name[name] begin[{] method[setCurrencyAttribute, return_type[void], modifier[public], parameter[name, value]] begin[{] call[.ensureAttributes, parameter[]] local_variable[type[Attribute], attribute] call[attribute.setEditable, parameter[call[.isEditable, para...
Keyword[public] Keyword[void] identifier[setCurrencyAttribute] operator[SEP] identifier[String] identifier[name] , identifier[String] identifier[value] operator[SEP] { identifier[ensureAttributes] operator[SEP] operator[SEP] operator[SEP] identifier[Attribute] identifier[attribute] operator[=] Keyword[new] iden...
public boolean matches(T target) { return target != null && matcher.matches(TypeDescription.ForLoadedType.of(target.getClass())); }
class class_name[name] begin[{] method[matches, return_type[type[boolean]], modifier[public], parameter[target]] begin[{] return[binary_operation[binary_operation[member[.target], !=, literal[null]], &&, call[matcher.matches, parameter[call[TypeDescription.ForLoadedType.of, parameter[call[target.getCla...
Keyword[public] Keyword[boolean] identifier[matches] operator[SEP] identifier[T] identifier[target] operator[SEP] { Keyword[return] identifier[target] operator[!=] Other[null] operator[&&] identifier[matcher] operator[SEP] identifier[matches] operator[SEP] identifier[TypeDescription] operator[SEP] identifier[For...
protected void init() { JButton testButton = new JButton(); oldDayBackgroundColor = testButton.getBackground(); selectedColor = new Color(160, 160, 160); Date date = calendar.getTime(); calendar = Calendar.getInstance(locale); calendar.setTime(date); drawDayNames(); drawDays(); }
class class_name[name] begin[{] method[init, return_type[void], modifier[protected], parameter[]] begin[{] local_variable[type[JButton], testButton] assign[member[.oldDayBackgroundColor], call[testButton.getBackground, parameter[]]] assign[member[.selectedColor], ClassCr...
Keyword[protected] Keyword[void] identifier[init] operator[SEP] operator[SEP] { identifier[JButton] identifier[testButton] operator[=] Keyword[new] identifier[JButton] operator[SEP] operator[SEP] operator[SEP] identifier[oldDayBackgroundColor] operator[=] identifier[testButton] operator[SEP] identifier[getBackgr...
private void addInputRow(String label, Widget inputWidget) { FlowPanel row = new FlowPanel(); row.setStyleName(I_CmsLayoutBundle.INSTANCE.generalCss().simpleFormRow()); CmsLabel labelWidget = new CmsLabel(label); labelWidget.setStyleName(I_CmsLayoutBundle.INSTANCE.generalCss().simpleFor...
class class_name[name] begin[{] method[addInputRow, return_type[void], modifier[private], parameter[label, inputWidget]] begin[{] local_variable[type[FlowPanel], row] call[row.setStyleName, parameter[call[I_CmsLayoutBundle.INSTANCE.generalCss, parameter[]]]] local_variable[type[...
Keyword[private] Keyword[void] identifier[addInputRow] operator[SEP] identifier[String] identifier[label] , identifier[Widget] identifier[inputWidget] operator[SEP] { identifier[FlowPanel] identifier[row] operator[=] Keyword[new] identifier[FlowPanel] operator[SEP] operator[SEP] operator[SEP] identifier[row] op...
public void moveLastChild( Row newParent ) { if( this == newParent ) return; // remove from its current position Row parentItem = m_parent; if( parentItem == null ) parentItem = this.treeTable.m_rootItem; parentItem.getChilds().remove( this ); // DOM.removeChild( m_body, m_tr ); if( newParent == ...
class class_name[name] begin[{] method[moveLastChild, return_type[void], modifier[public], parameter[newParent]] begin[{] if[binary_operation[THIS[], ==, member[.newParent]]] begin[{] return[None] else begin[{] None end[}] local_variable[type[Row], parentItem] ...
Keyword[public] Keyword[void] identifier[moveLastChild] operator[SEP] identifier[Row] identifier[newParent] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[==] identifier[newParent] operator[SEP] Keyword[return] operator[SEP] identifier[Row] identifier[parentItem] operator[=] identifier[m_parent...
private Set<File> getReadLocks() { final Set<File> readLocks = new HashSet<File>(); File[] lckFiles = this.lockPath.listFiles(lockFilter); for (final File lckFile : lckFiles) { if (lockFilter.isReaderLockFile(lckFile)) { readLocks.add(lckFile); } }...
class class_name[name] begin[{] method[getReadLocks, return_type[type[Set]], modifier[private], parameter[]] begin[{] local_variable[type[Set], readLocks] local_variable[type[File], lckFiles] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation...
Keyword[private] identifier[Set] operator[<] identifier[File] operator[>] identifier[getReadLocks] operator[SEP] operator[SEP] { Keyword[final] identifier[Set] operator[<] identifier[File] operator[>] identifier[readLocks] operator[=] Keyword[new] identifier[HashSet] operator[<] identifier[File] operator[>] oper...
public float getWidthCorrected(float charSpacing, float wordSpacing) { if (image != null) { return image.getScaledWidth() + charSpacing; } int numberOfSpaces = 0; int idx = -1; while ((idx = value.indexOf(' ', idx + 1)) >= 0) ++numberOfSpaces; ...
class class_name[name] begin[{] method[getWidthCorrected, return_type[type[float]], modifier[public], parameter[charSpacing, wordSpacing]] begin[{] if[binary_operation[member[.image], !=, literal[null]]] begin[{] return[binary_operation[call[image.getScaledWidth, parameter[]], +, me...
Keyword[public] Keyword[float] identifier[getWidthCorrected] operator[SEP] Keyword[float] identifier[charSpacing] , Keyword[float] identifier[wordSpacing] operator[SEP] { Keyword[if] operator[SEP] identifier[image] operator[!=] Other[null] operator[SEP] { Keyword[return] identifier[image] operator[SE...
public void run() throws Exception { if (config == null) { return; } SimpleRequest req = newRequest(); InetSocketAddress socketAddress = (InetSocketAddress) config.address; if (!config.tls) system.log().info("Using plaintext gRPC HTTP/2 connections"); GrpcClientSettings settings ...
class class_name[name] begin[{] method[run, return_type[void], modifier[public], parameter[]] begin[{] if[binary_operation[member[.config], ==, literal[null]]] begin[{] return[None] else begin[{] None end[}] local_variable[type[SimpleRequest], req] lo...
Keyword[public] Keyword[void] identifier[run] operator[SEP] operator[SEP] Keyword[throws] identifier[Exception] { Keyword[if] operator[SEP] identifier[config] operator[==] Other[null] operator[SEP] { Keyword[return] operator[SEP] } identifier[SimpleRequest] identifier[req] operator[=] id...
public boolean isSet(_Fields field) { if (field == null) { throw new IllegalArgumentException(); } switch (field) { case PORT: return is_set_port(); case UPTIME: return is_set_uptime(); case TOPOLOGY: return is_set_topology(); case TASKS: return is_set_tasks();...
class class_name[name] begin[{] method[isSet, return_type[type[boolean]], modifier[public], parameter[field]] begin[{] if[binary_operation[member[.field], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[], body=None, constructor_type_arguments=None, po...
Keyword[public] Keyword[boolean] identifier[isSet] operator[SEP] identifier[_Fields] identifier[field] operator[SEP] { Keyword[if] operator[SEP] identifier[field] operator[==] Other[null] operator[SEP] { Keyword[throw] Keyword[new] identifier[IllegalArgumentException] operator[SEP] operator[SEP] opera...
private Object handleTxWriteCommand(InvocationContext ctx, AbstractDataWriteCommand command, Object key) throws Throwable { try { if (!ctx.isOriginLocal()) { LocalizedCacheTopology cacheTopology = checkTopologyId(command); // Ignore any remote command when we aren't the o...
class class_name[name] begin[{] method[handleTxWriteCommand, return_type[type[Object]], modifier[private], parameter[ctx, command, key]] begin[{] TryStatement(block=[IfStatement(condition=MethodInvocation(arguments=[], member=isOriginLocal, postfix_operators=[], prefix_operators=['!'], qualifier=ctx, s...
Keyword[private] identifier[Object] identifier[handleTxWriteCommand] operator[SEP] identifier[InvocationContext] identifier[ctx] , identifier[AbstractDataWriteCommand] identifier[command] , identifier[Object] identifier[key] operator[SEP] Keyword[throws] identifier[Throwable] { Keyword[try] { Keywor...
static JSTypeExpression getTypeFromProperty( MemberDefinition property, AbstractCompiler compiler) { if (property.info != null && property.info.hasType()) { return property.info.getType(); } String typeString; if (property.value.isObjectLit()) { Node typeValue = NodeUtil.getFirstPropM...
class class_name[name] begin[{] method[getTypeFromProperty, return_type[type[JSTypeExpression]], modifier[static], parameter[property, compiler]] begin[{] if[binary_operation[binary_operation[member[property.info], !=, literal[null]], &&, call[property.info.hasType, parameter[]]]] begin[{] ...
Keyword[static] identifier[JSTypeExpression] identifier[getTypeFromProperty] operator[SEP] identifier[MemberDefinition] identifier[property] , identifier[AbstractCompiler] identifier[compiler] operator[SEP] { Keyword[if] operator[SEP] identifier[property] operator[SEP] identifier[info] operator[!=] Other[null] ...
public String deleteByIdList(MappedStatement ms) { final Class<?> entityClass = getEntityClass(ms); StringBuilder sql = new StringBuilder(); sql.append(SqlHelper.deleteFromTable(entityClass, tableName(entityClass))); appendWhereIdList(sql, entityClass, getConfig().isSafeDelete()); ...
class class_name[name] begin[{] method[deleteByIdList, return_type[type[String]], modifier[public], parameter[ms]] begin[{] local_variable[type[Class], entityClass] local_variable[type[StringBuilder], sql] call[sql.append, parameter[call[SqlHelper.deleteFromTable, parameter[memb...
Keyword[public] identifier[String] identifier[deleteByIdList] operator[SEP] identifier[MappedStatement] identifier[ms] operator[SEP] { Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifier[entityClass] operator[=] identifier[getEntityClass] operator[SEP] identifier[ms] operator[SEP] ope...
static void clear(byte[][] blocks, int off, int len) { // this is significantly faster than looping or Arrays.fill (which loops), particularly when // the length of the slice to be cleared is <= to ARRAY_LEN (in that case, it's faster by a // factor of 2) int remaining = len; while (remaining > ARRA...
class class_name[name] begin[{] method[clear, return_type[void], modifier[static], parameter[blocks, off, len]] begin[{] local_variable[type[int], remaining] while[binary_operation[member[.remaining], >, member[.ARRAY_LEN]]] begin[{] call[System.arraycopy, parame...
Keyword[static] Keyword[void] identifier[clear] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] operator[SEP] operator[SEP] identifier[blocks] , Keyword[int] identifier[off] , Keyword[int] identifier[len] operator[SEP] { Keyword[int] identifier[remaining] operator[=] identifier[len] operator[SEP] Keywo...
@CheckForNull public static PrivateKey loadPrivateKey(final Reader reader) throws IOException, NoSuchAlgorithmException, InvalidKeySpecException { try (PEMParser pemParser = new PEMParser(reader)) { Object readObject = pemParser.readObject(); while (readObject != null) { ...
class class_name[name] begin[{] method[loadPrivateKey, return_type[type[PrivateKey]], modifier[public static], parameter[reader]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[], member=readOb...
annotation[@] identifier[CheckForNull] Keyword[public] Keyword[static] identifier[PrivateKey] identifier[loadPrivateKey] operator[SEP] Keyword[final] identifier[Reader] identifier[reader] operator[SEP] Keyword[throws] identifier[IOException] , identifier[NoSuchAlgorithmException] , identifier[InvalidKeySpecException]...
public CompletableFuture<Void> registerEventProcessorFactory(IEventProcessorFactory<?> factory, EventProcessorOptions processorOptions) { if (this.unregistered != null) { throw new IllegalStateException("Register cannot be called on an EventProcessorHost after unregister. Please create a new EventPr...
class class_name[name] begin[{] method[registerEventProcessorFactory, return_type[type[CompletableFuture]], modifier[public], parameter[factory, processorOptions]] begin[{] if[binary_operation[THIS[member[None.unregistered]], !=, literal[null]]] begin[{] ThrowStatement(expression=Cl...
Keyword[public] identifier[CompletableFuture] operator[<] identifier[Void] operator[>] identifier[registerEventProcessorFactory] operator[SEP] identifier[IEventProcessorFactory] operator[<] operator[?] operator[>] identifier[factory] , identifier[EventProcessorOptions] identifier[processorOptions] operator[SEP] { ...
private void recycleBuffer(MemorySegment buffer) { synchronized (this.buffers) { if (this.isDestroyed) { this.globalBufferPool.returnBuffer(buffer); this.numRequestedBuffers--; } else { // if the number of designated buffers changed in the meantime, make sure // to return the buffer to the globa...
class class_name[name] begin[{] method[recycleBuffer, return_type[void], modifier[private], parameter[buffer]] begin[{] SYNCHRONIZED[THIS[member[None.buffers]]] BEGIN[{] if[THIS[member[None.isDestroyed]]] begin[{] THIS[member[None.globalBu...
Keyword[private] Keyword[void] identifier[recycleBuffer] operator[SEP] identifier[MemorySegment] identifier[buffer] operator[SEP] { Keyword[synchronized] operator[SEP] Keyword[this] operator[SEP] identifier[buffers] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[isDes...
public void removeUserProfileEventListener(UserProfileEventListener listener) { SecurityHelper.validateSecurityPermission(PermissionConstants.MANAGE_LISTENERS); listeners.remove(listener); }
class class_name[name] begin[{] method[removeUserProfileEventListener, return_type[void], modifier[public], parameter[listener]] begin[{] call[SecurityHelper.validateSecurityPermission, parameter[member[PermissionConstants.MANAGE_LISTENERS]]] call[listeners.remove, parameter[mem...
Keyword[public] Keyword[void] identifier[removeUserProfileEventListener] operator[SEP] identifier[UserProfileEventListener] identifier[listener] operator[SEP] { identifier[SecurityHelper] operator[SEP] identifier[validateSecurityPermission] operator[SEP] identifier[PermissionConstants] operator[SEP] identifier[M...
public static <T> List<T> randomListFrom(Iterable<T> elements, Range<Integer> size) { checkArgument(!isEmpty(elements), "Elements to populate from must not be empty"); return randomListFrom(() -> IterableUtils.randomFrom(elements), size); }
class class_name[name] begin[{] method[randomListFrom, return_type[type[List]], modifier[public static], parameter[elements, size]] begin[{] call[.checkArgument, parameter[call[.isEmpty, parameter[member[.elements]]], literal["Elements to populate from must not be empty"]]] return[call[...
Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[List] operator[<] identifier[T] operator[>] identifier[randomListFrom] operator[SEP] identifier[Iterable] operator[<] identifier[T] operator[>] identifier[elements] , identifier[Range] operator[<] identifier[Integer] operator[>] identifie...
public void resetPassword(CmsRequestContext context, String username, String oldPassword, String newPassword) throws CmsException, CmsSecurityException { CmsDbContext dbc = m_dbContextFactory.getDbContext(context); try { m_driverManager.resetPassword( dbc, ...
class class_name[name] begin[{] method[resetPassword, return_type[void], modifier[public], parameter[context, username, oldPassword, newPassword]] begin[{] local_variable[type[CmsDbContext], dbc] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(memb...
Keyword[public] Keyword[void] identifier[resetPassword] operator[SEP] identifier[CmsRequestContext] identifier[context] , identifier[String] identifier[username] , identifier[String] identifier[oldPassword] , identifier[String] identifier[newPassword] operator[SEP] Keyword[throws] identifier[CmsException] , identif...
static int countCityCoordinatesForCountry(final int codex, final int territoryRecord, final int firstTerritoryRecord) { assert codex >= 0; assert territoryRecord >= 0; assert firstTerritoryRecord >= 0; final int firstRecord = getFirstNamelessRecord(codex, territoryRecord, firstTerritoryR...
class class_name[name] begin[{] method[countCityCoordinatesForCountry, return_type[type[int]], modifier[static], parameter[codex, territoryRecord, firstTerritoryRecord]] begin[{] AssertStatement(condition=BinaryOperation(operandl=MemberReference(member=codex, postfix_operators=[], prefix_operators=[], ...
Keyword[static] Keyword[int] identifier[countCityCoordinatesForCountry] operator[SEP] Keyword[final] Keyword[int] identifier[codex] , Keyword[final] Keyword[int] identifier[territoryRecord] , Keyword[final] Keyword[int] identifier[firstTerritoryRecord] operator[SEP] { Keyword[assert] identifier[codex] operator...
private void initDecompressor(ChannelHandlerContext ctx, int streamId, Http2Headers headers, boolean endOfStream) throws Http2Exception { final Http2Stream stream = connection.stream(streamId); if (stream == null) { return; } Http2Decompressor decompressor = deco...
class class_name[name] begin[{] method[initDecompressor, return_type[void], modifier[private], parameter[ctx, streamId, headers, endOfStream]] begin[{] local_variable[type[Http2Stream], stream] if[binary_operation[member[.stream], ==, literal[null]]] begin[{] return[None] ...
Keyword[private] Keyword[void] identifier[initDecompressor] operator[SEP] identifier[ChannelHandlerContext] identifier[ctx] , Keyword[int] identifier[streamId] , identifier[Http2Headers] identifier[headers] , Keyword[boolean] identifier[endOfStream] operator[SEP] Keyword[throws] identifier[Http2Exception] { K...
public static IntSet mutableFrom(Set<Integer> integerSet) { if (integerSet instanceof SmallIntSet) { return (SmallIntSet) integerSet; } if (integerSet instanceof ConcurrentSmallIntSet) { return (ConcurrentSmallIntSet) integerSet; } return mutableCopyFrom(integerSet); }
class class_name[name] begin[{] method[mutableFrom, return_type[type[IntSet]], modifier[public static], parameter[integerSet]] begin[{] if[binary_operation[member[.integerSet], instanceof, type[SmallIntSet]]] begin[{] return[Cast(expression=MemberReference(member=integerSet, postfix...
Keyword[public] Keyword[static] identifier[IntSet] identifier[mutableFrom] operator[SEP] identifier[Set] operator[<] identifier[Integer] operator[>] identifier[integerSet] operator[SEP] { Keyword[if] operator[SEP] identifier[integerSet] Keyword[instanceof] identifier[SmallIntSet] operator[SEP] { Keywo...
private boolean setKey(UserContext context, UserTOTPKey key) throws GuacamoleException { // Get mutable set of attributes User self = context.self(); Map<String, String> attributes = new HashMap<String, String>(); // Set/overwrite current TOTP key state attributes.p...
class class_name[name] begin[{] method[setKey, return_type[type[boolean]], modifier[private], parameter[context, key]] begin[{] local_variable[type[User], self] local_variable[type[Map], attributes] call[attributes.put, parameter[member[TOTPUser.TOTP_KEY_SECRET_ATTRIBUTE_NAME], ...
Keyword[private] Keyword[boolean] identifier[setKey] operator[SEP] identifier[UserContext] identifier[context] , identifier[UserTOTPKey] identifier[key] operator[SEP] Keyword[throws] identifier[GuacamoleException] { identifier[User] identifier[self] operator[=] identifier[context] operator[SEP] identifier[self]...
public void putEDBObjectEntry(String key, Object value, Class<?> type) { putEDBObjectEntry(key, value, type.getName()); }
class class_name[name] begin[{] method[putEDBObjectEntry, return_type[void], modifier[public], parameter[key, value, type]] begin[{] call[.putEDBObjectEntry, parameter[member[.key], member[.value], call[type.getName, parameter[]]]] end[}] END[}]
Keyword[public] Keyword[void] identifier[putEDBObjectEntry] operator[SEP] identifier[String] identifier[key] , identifier[Object] identifier[value] , identifier[Class] operator[<] operator[?] operator[>] identifier[type] operator[SEP] { identifier[putEDBObjectEntry] operator[SEP] identifier[key] , identifier[...
public void csv(String file) throws IOException { CsvWriteOptions options = CsvWriteOptions.builder(file).build(); new CsvWriter().write(table, options); }
class class_name[name] begin[{] method[csv, return_type[void], modifier[public], parameter[file]] begin[{] local_variable[type[CsvWriteOptions], options] ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=None, sel...
Keyword[public] Keyword[void] identifier[csv] operator[SEP] identifier[String] identifier[file] operator[SEP] Keyword[throws] identifier[IOException] { identifier[CsvWriteOptions] identifier[options] operator[=] identifier[CsvWriteOptions] operator[SEP] identifier[builder] operator[SEP] identifier[file] operator...
protected final ResponseEntity<Response> setGreetingText(Payload[] greeting) { Event event = new Event().setGreeting(greeting); return restTemplate.postForEntity(fbMessengerProfileUrl, event, Response.class); }
class class_name[name] begin[{] method[setGreetingText, return_type[type[ResponseEntity]], modifier[final protected], parameter[greeting]] begin[{] local_variable[type[Event], event] return[call[restTemplate.postForEntity, parameter[member[.fbMessengerProfileUrl], member[.event], ClassReference...
Keyword[protected] Keyword[final] identifier[ResponseEntity] operator[<] identifier[Response] operator[>] identifier[setGreetingText] operator[SEP] identifier[Payload] operator[SEP] operator[SEP] identifier[greeting] operator[SEP] { identifier[Event] identifier[event] operator[=] Keyword[new] identifier[Event] o...
public void printPattern(int[] row, int[] column, int offset) { int size = row.length; if (size != column.length) throw new IllegalArgumentException( "All arrays must be of the same size"); for (int i = 0; i < size; ++i) format(Locale.ENGLISH, "%10d %1...
class class_name[name] begin[{] method[printPattern, return_type[void], modifier[public], parameter[row, column, offset]] begin[{] local_variable[type[int], size] if[binary_operation[member[.size], !=, member[column.length]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Li...
Keyword[public] Keyword[void] identifier[printPattern] operator[SEP] Keyword[int] operator[SEP] operator[SEP] identifier[row] , Keyword[int] operator[SEP] operator[SEP] identifier[column] , Keyword[int] identifier[offset] operator[SEP] { Keyword[int] identifier[size] operator[=] identifier[row] operator[SEP] i...
public static String asTitleCase(String text) { // special for _value, eg we want to let underscore be like a space text = text.replace('_', ' '); // remove double spaces text = text.replaceAll("\\s+", " "); // see: http://stackoverflow.com/questions/2559759/how-do-i-convert-ca...
class class_name[name] begin[{] method[asTitleCase, return_type[type[String]], modifier[public static], parameter[text]] begin[{] assign[member[.text], call[text.replace, parameter[literal['_'], literal[' ']]]] assign[member[.text], call[text.replaceAll, parameter[literal["\\s+"...
Keyword[public] Keyword[static] identifier[String] identifier[asTitleCase] operator[SEP] identifier[String] identifier[text] operator[SEP] { identifier[text] operator[=] identifier[text] operator[SEP] identifier[replace] operator[SEP] literal[String] , literal[String] operator[SEP] operator[SEP] identifier[text...
public static Jar getArchiveTask(Project project) { TaskCollection<Jar> existingArchiveTasks = project.getTasks().withType(Jar.class); Jar customArchiveTask = project.getExtensions().getByType(ThorntailExtension.class).getArchiveTask(); if (customArchiveTask != null) { return exist...
class class_name[name] begin[{] method[getArchiveTask, return_type[type[Jar]], modifier[public static], parameter[project]] begin[{] local_variable[type[TaskCollection], existingArchiveTasks] local_variable[type[Jar], customArchiveTask] if[binary_operation[member[.customArchiveT...
Keyword[public] Keyword[static] identifier[Jar] identifier[getArchiveTask] operator[SEP] identifier[Project] identifier[project] operator[SEP] { identifier[TaskCollection] operator[<] identifier[Jar] operator[>] identifier[existingArchiveTasks] operator[=] identifier[project] operator[SEP] identifier[getTasks] o...
public boolean isSentenceStart() { return posToken != null && JLanguageTool.SENTENCE_START_TAGNAME.equals(posToken.posTag) && !posToken.negation; }
class class_name[name] begin[{] method[isSentenceStart, return_type[type[boolean]], modifier[public], parameter[]] begin[{] return[binary_operation[binary_operation[binary_operation[member[.posToken], !=, literal[null]], &&, call[JLanguageTool.SENTENCE_START_TAGNAME.equals, parameter[member[posToken.po...
Keyword[public] Keyword[boolean] identifier[isSentenceStart] operator[SEP] operator[SEP] { Keyword[return] identifier[posToken] operator[!=] Other[null] operator[&&] identifier[JLanguageTool] operator[SEP] identifier[SENTENCE_START_TAGNAME] operator[SEP] identifier[equals] operator[SEP] identifier[posToken] oper...
public String getID() { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "getID"); String id = _streamId.toString(); if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(tc, "getID", id); return id; }
class class_name[name] begin[{] method[getID, return_type[type[String]], modifier[public], parameter[]] begin[{] if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{] call[SibTr.entry, parameter[member[.tc], li...
Keyword[public] identifier[String] identifier[getID] 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] operat...
public void addVisualizationListener(VisualizationListener listener) { for(int i = 0; i < vlistenerList.size(); i++) { if(vlistenerList.get(i) == listener) { return; } } vlistenerList.add(listener); }
class class_name[name] begin[{] method[addVisualizationListener, return_type[void], modifier[public], parameter[listener]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MethodInvocation(arguments=[MemberReference(member=i, postfix_opera...
Keyword[public] Keyword[void] identifier[addVisualizationListener] operator[SEP] identifier[VisualizationListener] identifier[listener] operator[SEP] { Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] identifier[vlistenerList] operator[SEP] identi...
public static <S extends Control, V> SkinPropertyBasedCssMetaData<S, V> createSkinMetaData(String property, StyleConverter<?, V> converter, String propertyName, V defaultValue) { return new SkinPropertyBasedCssMetaData<S, V>(property, converter, propertyName, defaultValue); }
class class_name[name] begin[{] method[createSkinMetaData, return_type[type[SkinPropertyBasedCssMetaData]], modifier[public static], parameter[property, converter, propertyName, defaultValue]] begin[{] return[ClassCreator(arguments=[MemberReference(member=property, postfix_operators=[], prefix_operator...
Keyword[public] Keyword[static] operator[<] identifier[S] Keyword[extends] identifier[Control] , identifier[V] operator[>] identifier[SkinPropertyBasedCssMetaData] operator[<] identifier[S] , identifier[V] operator[>] identifier[createSkinMetaData] operator[SEP] identifier[String] identifier[property] , identifier[S...
public ServiceFuture<List<NetworkWatcherInner>> listAsync(final ServiceCallback<List<NetworkWatcherInner>> serviceCallback) { return ServiceFuture.fromResponse(listWithServiceResponseAsync(), serviceCallback); }
class class_name[name] begin[{] method[listAsync, return_type[type[ServiceFuture]], modifier[public], parameter[serviceCallback]] begin[{] return[call[ServiceFuture.fromResponse, parameter[call[.listWithServiceResponseAsync, parameter[]], member[.serviceCallback]]]] end[}] END[}]
Keyword[public] identifier[ServiceFuture] operator[<] identifier[List] operator[<] identifier[NetworkWatcherInner] operator[>] operator[>] identifier[listAsync] operator[SEP] Keyword[final] identifier[ServiceCallback] operator[<] identifier[List] operator[<] identifier[NetworkWatcherInner] operator[>] operator[>] ident...
public StoredChannel setClientToken(String clientToken) { lock.lock(); try { this.clientToken = clientToken; } finally { lock.unlock(); } return this; }
class class_name[name] begin[{] method[setClientToken, return_type[type[StoredChannel]], modifier[public], parameter[clientToken]] begin[{] call[lock.lock, parameter[]] TryStatement(block=[StatementExpression(expression=Assignment(expressionl=This(postfix_operators=[], prefix_operators=...
Keyword[public] identifier[StoredChannel] identifier[setClientToken] operator[SEP] identifier[String] identifier[clientToken] operator[SEP] { identifier[lock] operator[SEP] identifier[lock] operator[SEP] operator[SEP] operator[SEP] Keyword[try] { Keyword[this] operator[SEP] identifier[clientToken] ope...
@Override public void stop() { lock.lock(); try { if (process != null) { destroyProcess(); } process = null; } finally { lock.unlock(); } }
class class_name[name] begin[{] method[stop, return_type[void], modifier[public], parameter[]] begin[{] call[lock.lock, parameter[]] TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=process, postfix_operators=[], prefix_operators=[], qualifier=, ...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[stop] operator[SEP] operator[SEP] { identifier[lock] operator[SEP] identifier[lock] operator[SEP] operator[SEP] operator[SEP] Keyword[try] { Keyword[if] operator[SEP] identifier[process] operator[!=] Other[null] operator[SEP] ...
public void put(int key, int value) { if (key < 0) Kit.codeBug(); int index = ensureIndex(key, true); if (ivaluesShift == 0) { int N = 1 << power; // keys.length can be N * 2 after clear which set ivaluesShift to 0 if (keys.length != N * 2) { i...
class class_name[name] begin[{] method[put, return_type[void], modifier[public], parameter[key, value]] begin[{] if[binary_operation[member[.key], <, literal[0]]] begin[{] call[Kit.codeBug, parameter[]] else begin[{] None end[}] local_variable[type[int], inde...
Keyword[public] Keyword[void] identifier[put] operator[SEP] Keyword[int] identifier[key] , Keyword[int] identifier[value] operator[SEP] { Keyword[if] operator[SEP] identifier[key] operator[<] Other[0] operator[SEP] identifier[Kit] operator[SEP] identifier[codeBug] operator[SEP] operator[SEP] operator[SEP] Keywo...
private void setModelContext(InstancesHeader ih){ //TODO possibly refactored if ((ih != null) && (ih.classIndex() < 0)) { throw new IllegalArgumentException( "Context for a classifier must include a class to learn"); } //TODO: check flag for checking whether tra...
class class_name[name] begin[{] method[setModelContext, return_type[void], modifier[private], parameter[ih]] begin[{] if[binary_operation[binary_operation[member[.ih], !=, literal[null]], &&, binary_operation[call[ih.classIndex, parameter[]], <, literal[0]]]] begin[{] ThrowStatement...
Keyword[private] Keyword[void] identifier[setModelContext] operator[SEP] identifier[InstancesHeader] identifier[ih] operator[SEP] { Keyword[if] operator[SEP] operator[SEP] identifier[ih] operator[!=] Other[null] operator[SEP] operator[&&] operator[SEP] identifier[ih] operator[SEP] identifier[classIndex] operator...
public void execute() throws HelloSignException { HttpURLConnection connection = getConnection(); try { // Execute the request and save the HTTP status code lastHttpStatusCode = connection.getResponseCode(); // Save the stream object for processing if (la...
class class_name[name] begin[{] method[execute, return_type[void], modifier[public], parameter[]] begin[{] local_variable[type[HttpURLConnection], connection] TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(member=lastHttpStatusCode, postfix_operators=[...
Keyword[public] Keyword[void] identifier[execute] operator[SEP] operator[SEP] Keyword[throws] identifier[HelloSignException] { identifier[HttpURLConnection] identifier[connection] operator[=] identifier[getConnection] operator[SEP] operator[SEP] operator[SEP] Keyword[try] { identifier[lastHttpStatusCo...
@Override protected Integer doBase(String name, Object value) { if (value instanceof Number) { return ((Number) value).intValue(); } else if (value instanceof Date) { return SimpleDateSerializer.timeInMillisToDay(((Date) value).getTime()); } else if (value instanceof ...
class class_name[name] begin[{] method[doBase, return_type[type[Integer]], modifier[protected], parameter[name, value]] begin[{] if[binary_operation[member[.value], instanceof, type[Number]]] begin[{] return[Cast(expression=MemberReference(member=value, postfix_operators=[], prefix_...
annotation[@] identifier[Override] Keyword[protected] identifier[Integer] identifier[doBase] operator[SEP] identifier[String] identifier[name] , identifier[Object] identifier[value] operator[SEP] { Keyword[if] operator[SEP] identifier[value] Keyword[instanceof] identifier[Number] operator[SEP] { Keyw...
public Set<Resource<L>> getRootResources() { graphLockRead.lock(); try { Set<Resource<L>> roots = new HashSet<>(); Set<Resource<L>> allResources = resourcesGraph.vertexSet(); for (Resource<L> resource : allResources) { if (neighborIndex.predecessorsOf(...
class class_name[name] begin[{] method[getRootResources, return_type[type[Set]], modifier[public], parameter[]] begin[{] call[graphLockRead.lock, parameter[]] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=ClassCre...
Keyword[public] identifier[Set] operator[<] identifier[Resource] operator[<] identifier[L] operator[>] operator[>] identifier[getRootResources] operator[SEP] operator[SEP] { identifier[graphLockRead] operator[SEP] identifier[lock] operator[SEP] operator[SEP] operator[SEP] Keyword[try] { identifier[Set...
public byte[] getFrameData(String id) { if (frames.containsKey(id)) { return ((ID3v2Frame) frames.get(id)).getFrameData(); } return null; }
class class_name[name] begin[{] method[getFrameData, return_type[type[byte]], modifier[public], parameter[id]] begin[{] if[call[frames.containsKey, parameter[member[.id]]]] begin[{] return[Cast(expression=MethodInvocation(arguments=[MemberReference(member=id, postfix_operators=[], p...
Keyword[public] Keyword[byte] operator[SEP] operator[SEP] identifier[getFrameData] operator[SEP] identifier[String] identifier[id] operator[SEP] { Keyword[if] operator[SEP] identifier[frames] operator[SEP] identifier[containsKey] operator[SEP] identifier[id] operator[SEP] operator[SEP] { Keyword[retur...
public static <T> Maybe<List<T>> values(String key, Class<T> vClazz) { return values(CacheService.CACHE_CONFIG_BEAN, key, vClazz); }
class class_name[name] begin[{] method[values, return_type[type[Maybe]], modifier[public static], parameter[key, vClazz]] begin[{] return[call[.values, parameter[member[CacheService.CACHE_CONFIG_BEAN], member[.key], member[.vClazz]]]] end[}] END[}]
Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[Maybe] operator[<] identifier[List] operator[<] identifier[T] operator[>] operator[>] identifier[values] operator[SEP] identifier[String] identifier[key] , identifier[Class] operator[<] identifier[T] operator[>] identifier[vClazz] operato...
public final WebPage getRootPage() throws IOException, SQLException { WebPage page = this; WebPage parent; while ((parent = page.getParent()) != null) page = parent; return page; }
class class_name[name] begin[{] method[getRootPage, return_type[type[WebPage]], modifier[final public], parameter[]] begin[{] local_variable[type[WebPage], page] local_variable[type[WebPage], parent] while[binary_operation[assign[member[.parent], call[page.getParent, parameter[]...
Keyword[public] Keyword[final] identifier[WebPage] identifier[getRootPage] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] , identifier[SQLException] { identifier[WebPage] identifier[page] operator[=] Keyword[this] operator[SEP] identifier[WebPage] identifier[parent] operator[SEP] Keyword[wh...
public static <U> Stream<U> takeWhile(final Stream<U> stream, final Predicate<? super U> predicate) { return StreamSupport.stream(new LimitWhileSpliterator<>(stream.spliterator(), predicate),stream.isParallel()); }
class class_name[name] begin[{] method[takeWhile, return_type[type[Stream]], modifier[public static], parameter[stream, predicate]] begin[{] return[call[StreamSupport.stream, parameter[ClassCreator(arguments=[MethodInvocation(arguments=[], member=spliterator, postfix_operators=[], prefix_operators=[], ...
Keyword[public] Keyword[static] operator[<] identifier[U] operator[>] identifier[Stream] operator[<] identifier[U] operator[>] identifier[takeWhile] operator[SEP] Keyword[final] identifier[Stream] operator[<] identifier[U] operator[>] identifier[stream] , Keyword[final] identifier[Predicate] operator[<] operator[?] Ke...
protected int getWaitPeriodInSeconds() throws ActivityException { String unit = super.getAttributeValue(WAIT_UNIT); int factor; if (MINUTES.equals(unit)) factor = 60; else if (HOURS.equals(unit)) factor = 3600; else if (DAYS.equals(unit)) factor = 86400; else factor = 1; ...
class class_name[name] begin[{] method[getWaitPeriodInSeconds, return_type[type[int]], modifier[protected], parameter[]] begin[{] local_variable[type[String], unit] local_variable[type[int], factor] if[call[MINUTES.equals, parameter[member[.unit]]]] begin[{] assign[m...
Keyword[protected] Keyword[int] identifier[getWaitPeriodInSeconds] operator[SEP] operator[SEP] Keyword[throws] identifier[ActivityException] { identifier[String] identifier[unit] operator[=] Keyword[super] operator[SEP] identifier[getAttributeValue] operator[SEP] identifier[WAIT_UNIT] operator[SEP] operator[SEP]...
public void remoteGoto(String filename, String name, float llx, float lly, float urx, float ury) { pdf.remoteGoto(filename, name, llx, lly, urx, ury); }
class class_name[name] begin[{] method[remoteGoto, return_type[void], modifier[public], parameter[filename, name, llx, lly, urx, ury]] begin[{] call[pdf.remoteGoto, parameter[member[.filename], member[.name], member[.llx], member[.lly], member[.urx], member[.ury]]] end[}] END[}]
Keyword[public] Keyword[void] identifier[remoteGoto] operator[SEP] identifier[String] identifier[filename] , identifier[String] identifier[name] , Keyword[float] identifier[llx] , Keyword[float] identifier[lly] , Keyword[float] identifier[urx] , Keyword[float] identifier[ury] operator[SEP] { identifier[pdf]...
private static void collectPrefixes(FieldInfos fieldInfos, String field, ComponentField fieldInfo, Status status) throws IOException { if (fieldInfo.prefix != null) { FieldInfo fi = fieldInfos.fieldInfo(field); if (fi != null) { String singlePositionPrefixes = fi.getAttribute( ...
class class_name[name] begin[{] method[collectPrefixes, return_type[void], modifier[private static], parameter[fieldInfos, field, fieldInfo, status]] begin[{] if[binary_operation[member[fieldInfo.prefix], !=, literal[null]]] begin[{] local_variable[type[FieldInfo], fi] ...
Keyword[private] Keyword[static] Keyword[void] identifier[collectPrefixes] operator[SEP] identifier[FieldInfos] identifier[fieldInfos] , identifier[String] identifier[field] , identifier[ComponentField] identifier[fieldInfo] , identifier[Status] identifier[status] operator[SEP] Keyword[throws] identifier[IOException...
private void processEmbeddableAttribute(Object entity, MetamodelImpl metamodel, Row row, Table schemaTable, EntityMetadata metadata, Attribute attribute) { // process on embeddables. EmbeddableType embeddable = metamodel.embeddable(((AbstractAttribute) attribute).getBindableJavaType()); ...
class class_name[name] begin[{] method[processEmbeddableAttribute, return_type[void], modifier[private], parameter[entity, metamodel, row, schemaTable, metadata, attribute]] begin[{] local_variable[type[EmbeddableType], embeddable] local_variable[type[Set], embeddedAttributes] local_var...
Keyword[private] Keyword[void] identifier[processEmbeddableAttribute] operator[SEP] identifier[Object] identifier[entity] , identifier[MetamodelImpl] identifier[metamodel] , identifier[Row] identifier[row] , identifier[Table] identifier[schemaTable] , identifier[EntityMetadata] identifier[metadata] , identifier[At...
public static <T> VertxCompletableFuture<T> supplyBlockingAsync(Context context, Supplier<T> supplier) { Objects.requireNonNull(supplier); VertxCompletableFuture<T> future = new VertxCompletableFuture<>(context); context.<T>executeBlocking( fut -> { try { fut.complete(supplier....
class class_name[name] begin[{] method[supplyBlockingAsync, return_type[type[VertxCompletableFuture]], modifier[public static], parameter[context, supplier]] begin[{] call[Objects.requireNonNull, parameter[member[.supplier]]] local_variable[type[VertxCompletableFuture], future] ...
Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[VertxCompletableFuture] operator[<] identifier[T] operator[>] identifier[supplyBlockingAsync] operator[SEP] identifier[Context] identifier[context] , identifier[Supplier] operator[<] identifier[T] operator[>] identifier[supplier] operator...
public Iterable<Integer> index() { return () -> new Iterator<Integer>() { private final Iterator<Integer> it = data.records.keySet().iterator(); /** {@inheritDoc} */ @Override public boolean hasNext() { return it.hasNext(); } ...
class class_name[name] begin[{] method[index, return_type[type[Iterable]], modifier[public], parameter[]] begin[{] return[LambdaExpression(body=ClassCreator(arguments=[], body=[FieldDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[], mem...
Keyword[public] identifier[Iterable] operator[<] identifier[Integer] operator[>] identifier[index] operator[SEP] operator[SEP] { Keyword[return] operator[SEP] operator[SEP] operator[->] Keyword[new] identifier[Iterator] operator[<] identifier[Integer] operator[>] operator[SEP] operator[SEP] { Keyword[...
private static String escapeXml(final String text, final XmlEscapeSymbols symbols, final XmlEscapeType type, final XmlEscapeLevel level) { if (type == null) { throw new IllegalArgumentException("The 'type' argument cannot be null"); } if (level =...
class class_name[name] begin[{] method[escapeXml, return_type[type[String]], modifier[private static], parameter[text, symbols, type, level]] begin[{] if[binary_operation[member[.type], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_op...
Keyword[private] Keyword[static] identifier[String] identifier[escapeXml] operator[SEP] Keyword[final] identifier[String] identifier[text] , Keyword[final] identifier[XmlEscapeSymbols] identifier[symbols] , Keyword[final] identifier[XmlEscapeType] identifier[type] , Keyword[final] identifier[XmlEscapeLevel] identifi...
public Datum<E> add(E x, int y) { if (response == null) { throw new IllegalArgumentException(DATASET_HAS_NO_RESPONSE); } if (response.getType() != Attribute.Type.NOMINAL) { throw new IllegalArgumentException(RESPONSE_NOT_NOMINAL); } retur...
class class_name[name] begin[{] method[add, return_type[type[Datum]], modifier[public], parameter[x, y]] begin[{] if[binary_operation[member[.response], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[MemberReference(member=DATASET_HAS_NO_RESPONSE, pos...
Keyword[public] identifier[Datum] operator[<] identifier[E] operator[>] identifier[add] operator[SEP] identifier[E] identifier[x] , Keyword[int] identifier[y] operator[SEP] { Keyword[if] operator[SEP] identifier[response] operator[==] Other[null] operator[SEP] { Keyword[throw] Keyword[new] identifier...
public Email bcc(final EmailAddress... bccs) { this.bcc = ArraysUtil.join(this.bcc, valueOrEmptyArray(bccs)); return _this(); }
class class_name[name] begin[{] method[bcc, return_type[type[Email]], modifier[public], parameter[bccs]] begin[{] assign[THIS[member[None.bcc]], call[ArraysUtil.join, parameter[THIS[member[None.bcc]], call[.valueOrEmptyArray, parameter[member[.bccs]]]]]] return[call[._this, parameter[]]...
Keyword[public] identifier[Email] identifier[bcc] operator[SEP] Keyword[final] identifier[EmailAddress] operator[...] identifier[bccs] operator[SEP] { Keyword[this] operator[SEP] identifier[bcc] operator[=] identifier[ArraysUtil] operator[SEP] identifier[join] operator[SEP] Keyword[this] operator[SEP] identifier...
static double computeEuclidean(IntTuple t0, IntTuple t1) { return Math.sqrt(computeEuclideanSquared(t0, t1)); }
class class_name[name] begin[{] method[computeEuclidean, return_type[type[double]], modifier[static], parameter[t0, t1]] begin[{] return[call[Math.sqrt, parameter[call[.computeEuclideanSquared, parameter[member[.t0], member[.t1]]]]]] end[}] END[}]
Keyword[static] Keyword[double] identifier[computeEuclidean] operator[SEP] identifier[IntTuple] identifier[t0] , identifier[IntTuple] identifier[t1] operator[SEP] { Keyword[return] identifier[Math] operator[SEP] identifier[sqrt] operator[SEP] identifier[computeEuclideanSquared] operator[SEP] identifier[t0] , i...
public static void foreachRandomInt(int streamSize, Random random, int exclusiveBound, IntConsumer eachRandomIntConsumer) { foreachRandomInt(streamSize, () -> random.nextInt(exclusiveBound), eachRandomIntConsumer); }
class class_name[name] begin[{] method[foreachRandomInt, return_type[void], modifier[public static], parameter[streamSize, random, exclusiveBound, eachRandomIntConsumer]] begin[{] call[.foreachRandomInt, parameter[member[.streamSize], LambdaExpression(body=MethodInvocation(arguments=[MemberRefe...
Keyword[public] Keyword[static] Keyword[void] identifier[foreachRandomInt] operator[SEP] Keyword[int] identifier[streamSize] , identifier[Random] identifier[random] , Keyword[int] identifier[exclusiveBound] , identifier[IntConsumer] identifier[eachRandomIntConsumer] operator[SEP] { identifier[foreachRandomInt...
public HttpResponse head(String path) throws APIException { final HttpHead request = new HttpHead(getUrl(path)); return executeHead(request); }
class class_name[name] begin[{] method[head, return_type[type[HttpResponse]], modifier[public], parameter[path]] begin[{] local_variable[type[HttpHead], request] return[call[.executeHead, parameter[member[.request]]]] end[}] END[}]
Keyword[public] identifier[HttpResponse] identifier[head] operator[SEP] identifier[String] identifier[path] operator[SEP] Keyword[throws] identifier[APIException] { Keyword[final] identifier[HttpHead] identifier[request] operator[=] Keyword[new] identifier[HttpHead] operator[SEP] identifier[getUrl] operator[SEP]...
public IPAddressSeqRange join(IPAddressSeqRange other) { IPAddress otherLower = other.getLower(); IPAddress otherUpper = other.getUpper(); IPAddress lower = this.getLower(); IPAddress upper = this.getUpper(); int lowerComp = compareLowValues(lower, otherLower); if(!overlaps(other)) { if(lowerComp >= 0) {...
class class_name[name] begin[{] method[join, return_type[type[IPAddressSeqRange]], modifier[public], parameter[other]] begin[{] local_variable[type[IPAddress], otherLower] local_variable[type[IPAddress], otherUpper] local_variable[type[IPAddress], lower] local_variable[type[IPAd...
Keyword[public] identifier[IPAddressSeqRange] identifier[join] operator[SEP] identifier[IPAddressSeqRange] identifier[other] operator[SEP] { identifier[IPAddress] identifier[otherLower] operator[=] identifier[other] operator[SEP] identifier[getLower] operator[SEP] operator[SEP] operator[SEP] identifier[IPAddress...
public Matrix4f setPerspectiveLH(float fovy, float aspect, float zNear, float zFar) { return setPerspectiveLH(fovy, aspect, zNear, zFar, false); }
class class_name[name] begin[{] method[setPerspectiveLH, return_type[type[Matrix4f]], modifier[public], parameter[fovy, aspect, zNear, zFar]] begin[{] return[call[.setPerspectiveLH, parameter[member[.fovy], member[.aspect], member[.zNear], member[.zFar], literal[false]]]] end[}] END[}]
Keyword[public] identifier[Matrix4f] identifier[setPerspectiveLH] operator[SEP] Keyword[float] identifier[fovy] , Keyword[float] identifier[aspect] , Keyword[float] identifier[zNear] , Keyword[float] identifier[zFar] operator[SEP] { Keyword[return] identifier[setPerspectiveLH] operator[SEP] identifier[fovy] ,...
public static Intent createAuthorizationIntent(Context context, String authorizationUrl, boolean forceThirdPartyApp) { Intent intent; if (!forceThirdPartyApp && EvernoteInstallStatus.INSTALLED.equals(getEvernoteInstallStatus(context, ACTION_AUTHORIZE))) { intent = new Intent(ACTION_AUTHORIZ...
class class_name[name] begin[{] method[createAuthorizationIntent, return_type[type[Intent]], modifier[public static], parameter[context, authorizationUrl, forceThirdPartyApp]] begin[{] local_variable[type[Intent], intent] if[binary_operation[member[.forceThirdPartyApp], &&, call[Evernot...
Keyword[public] Keyword[static] identifier[Intent] identifier[createAuthorizationIntent] operator[SEP] identifier[Context] identifier[context] , identifier[String] identifier[authorizationUrl] , Keyword[boolean] identifier[forceThirdPartyApp] operator[SEP] { identifier[Intent] identifier[intent] operator[SEP] ...
private void validateRecordedMapping() { if (currentMapping.destinationMutators == null || currentMapping.destinationMutators.isEmpty()) errors.missingDestination(); // If mapping a field without a source else if (options.skipType == 0 && (currentMapping.sourceAccessors == null || current...
class class_name[name] begin[{] method[validateRecordedMapping, return_type[void], modifier[private], parameter[]] begin[{] if[binary_operation[binary_operation[member[currentMapping.destinationMutators], ==, literal[null]], ||, call[currentMapping.destinationMutators.isEmpty, parameter[]]]] be...
Keyword[private] Keyword[void] identifier[validateRecordedMapping] operator[SEP] operator[SEP] { Keyword[if] operator[SEP] identifier[currentMapping] operator[SEP] identifier[destinationMutators] operator[==] Other[null] operator[||] identifier[currentMapping] operator[SEP] identifier[destinationMutators] operat...
public boolean isEdge(final ODocument iRecord) { return iRecord != null ? iRecord.getSchemaClass().isSubClassOf(edgeBaseClass) : false; }
class class_name[name] begin[{] method[isEdge, return_type[type[boolean]], modifier[public], parameter[iRecord]] begin[{] return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=iRecord, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), operandr=Literal(po...
Keyword[public] Keyword[boolean] identifier[isEdge] operator[SEP] Keyword[final] identifier[ODocument] identifier[iRecord] operator[SEP] { Keyword[return] identifier[iRecord] operator[!=] Other[null] operator[?] identifier[iRecord] operator[SEP] identifier[getSchemaClass] operator[SEP] operator[SEP] operator[SEP...
public void setPosition(CmsPositionBean position, CmsPositionBean buttonsPosition, Element containerElement) { m_position = position; Element parent = CmsDomUtil.getPositioningParent(getElement()); Style style = getElement().getStyle(); style.setRight( parent.getOffsetWidth(...
class class_name[name] begin[{] method[setPosition, return_type[void], modifier[public], parameter[position, buttonsPosition, containerElement]] begin[{] assign[member[.m_position], member[.position]] local_variable[type[Element], parent] local_variable[type[Style], style] ...
Keyword[public] Keyword[void] identifier[setPosition] operator[SEP] identifier[CmsPositionBean] identifier[position] , identifier[CmsPositionBean] identifier[buttonsPosition] , identifier[Element] identifier[containerElement] operator[SEP] { identifier[m_position] operator[=] identifier[position] operator[SEP]...
public String readString(final String charset) throws IOException { byte ch; int cnt = 0; final byte [] byteArrBuff = new byte[byteBuffer.remaining()]; while (byteBuffer.remaining() > 0 && ((ch = byteBuffer.get()) != 0)) { byteArrBuff[cnt++] = ch; } return new...
class class_name[name] begin[{] method[readString, return_type[type[String]], modifier[public], parameter[charset]] begin[{] local_variable[type[byte], ch] local_variable[type[int], cnt] local_variable[type[byte], byteArrBuff] while[binary_operation[binary_operation[call...
Keyword[public] identifier[String] identifier[readString] operator[SEP] Keyword[final] identifier[String] identifier[charset] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[byte] identifier[ch] operator[SEP] Keyword[int] identifier[cnt] operator[=] Other[0] operator[SEP] Keyword[final] Keyword[b...
private acolyte.jdbc.Blob createBlob(InputStream stream, long length) throws SQLException { final acolyte.jdbc.Blob blob = acolyte.jdbc.Blob.Nil(); blob.setBytes(0L, createBytes(stream, length)); return blob; }
class class_name[name] begin[{] method[createBlob, return_type[type[acolyte]], modifier[private], parameter[stream, length]] begin[{] local_variable[type[acolyte], blob] call[blob.setBytes, parameter[literal[0L], call[.createBytes, parameter[member[.stream], member[.length]]]]] ...
Keyword[private] identifier[acolyte] operator[SEP] identifier[jdbc] operator[SEP] identifier[Blob] identifier[createBlob] operator[SEP] identifier[InputStream] identifier[stream] , Keyword[long] identifier[length] operator[SEP] Keyword[throws] identifier[SQLException] { Keyword[final] identifier[acolyte] operat...
private List<Row> run(View from, Predicate<Row> predicate) { return StreamSupport.stream(from.rows().spliterator(), false) .filter(predicate) .collect(Collectors.toList()); }
class class_name[name] begin[{] method[run, return_type[type[List]], modifier[private], parameter[from, predicate]] begin[{] return[call[StreamSupport.stream, parameter[call[from.rows, parameter[]], literal[false]]]] end[}] END[}]
Keyword[private] identifier[List] operator[<] identifier[Row] operator[>] identifier[run] operator[SEP] identifier[View] identifier[from] , identifier[Predicate] operator[<] identifier[Row] operator[>] identifier[predicate] operator[SEP] { Keyword[return] identifier[StreamSupport] operator[SEP] identifier[strea...