code
stringlengths
63
466k
code_sememe
stringlengths
141
3.79M
token_type
stringlengths
274
1.23M
public DirectoryStream<Path> newDirectoryStream( JimfsPath dir, DirectoryStream.Filter<? super Path> filter, Set<? super LinkOption> options, JimfsPath basePathForStream) throws IOException { Directory file = (Directory) lookUpWithLock(dir, options).requireDirectory(dir).file(); Fi...
class class_name[name] begin[{] method[newDirectoryStream, return_type[type[DirectoryStream]], modifier[public], parameter[dir, filter, options, basePathForStream]] begin[{] local_variable[type[Directory], file] local_variable[type[FileSystemView], view] local_variable[type[JimfsSecureD...
Keyword[public] identifier[DirectoryStream] operator[<] identifier[Path] operator[>] identifier[newDirectoryStream] operator[SEP] identifier[JimfsPath] identifier[dir] , identifier[DirectoryStream] operator[SEP] identifier[Filter] operator[<] operator[?] Keyword[super] identifier[Path] operator[>] identifier[filter] ,...
public boolean shouldYieldFocus(JComponent input) { boolean isValidInput = verify(input); if (isValidInput) { input.setBackground(background); } else { input.setBackground(warningBackground); } return isValidInput; }
class class_name[name] begin[{] method[shouldYieldFocus, return_type[type[boolean]], modifier[public], parameter[input]] begin[{] local_variable[type[boolean], isValidInput] if[member[.isValidInput]] begin[{] call[input.setBackground, parameter[member[.background...
Keyword[public] Keyword[boolean] identifier[shouldYieldFocus] operator[SEP] identifier[JComponent] identifier[input] operator[SEP] { Keyword[boolean] identifier[isValidInput] operator[=] identifier[verify] operator[SEP] identifier[input] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[isValidInp...
private JarFile getJarFile(String jarFileUrl) throws IOException { if (jarFileUrl.startsWith("file:")) { try { final URI uri = new URI(jarFileUrl.replaceAll(" ", "\\%20")); final String jarFileName = uri.getSchemeSpecificPart(); logger.info("Creating n...
class class_name[name] begin[{] method[getJarFile, return_type[type[JarFile]], modifier[private], parameter[jarFileUrl]] begin[{] if[call[jarFileUrl.startsWith, parameter[literal["file:"]]]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableD...
Keyword[private] identifier[JarFile] identifier[getJarFile] operator[SEP] identifier[String] identifier[jarFileUrl] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[if] operator[SEP] identifier[jarFileUrl] operator[SEP] identifier[startsWith] operator[SEP] literal[String] operator[SEP] operator[SE...
private List<Group> populateList(final int numStdDev, final int limit) { final List<Group> list = new ArrayList<>(); for (int i = 0; i < mapArrSize; i++) { if (hashArr[i] != 0) { final String priKey = priKeyArr[i]; final int count = counterArr[i]; final double est = sketch.getEstim...
class class_name[name] begin[{] method[populateList, return_type[type[List]], modifier[private], parameter[numStdDev, limit]] begin[{] local_variable[type[List], list] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=...
Keyword[private] identifier[List] operator[<] identifier[Group] operator[>] identifier[populateList] operator[SEP] Keyword[final] Keyword[int] identifier[numStdDev] , Keyword[final] Keyword[int] identifier[limit] operator[SEP] { Keyword[final] identifier[List] operator[<] identifier[Group] operator[>] identifie...
public int characterAt(int at) throws JSONException { int c = get(at); if ((c & 0x80) == 0) { return c; } int character; int c1 = get(at + 1); if ((c1 & 0x80) == 0) { character = ((c & 0x7F) << 7) | c1; if (character > 0x7F) { ...
class class_name[name] begin[{] method[characterAt, return_type[type[int]], modifier[public], parameter[at]] begin[{] local_variable[type[int], c] if[binary_operation[binary_operation[member[.c], &, literal[0x80]], ==, literal[0]]] begin[{] return[member[.c]] else be...
Keyword[public] Keyword[int] identifier[characterAt] operator[SEP] Keyword[int] identifier[at] operator[SEP] Keyword[throws] identifier[JSONException] { Keyword[int] identifier[c] operator[=] identifier[get] operator[SEP] identifier[at] operator[SEP] operator[SEP] Keyword[if] operator[SEP] operator[SEP] identifi...
public static <D extends Comparable> NumberExpression<Integer> datediff(DatePart unit, DateExpression<D> start, DateExpression<D> end) { return Expressions.numberOperation(Integer.class, DATE_DIFF_OPS.get(unit), start, end); }
class class_name[name] begin[{] method[datediff, return_type[type[NumberExpression]], modifier[public static], parameter[unit, start, end]] begin[{] return[call[Expressions.numberOperation, parameter[ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type=ReferenceType(...
Keyword[public] Keyword[static] operator[<] identifier[D] Keyword[extends] identifier[Comparable] operator[>] identifier[NumberExpression] operator[<] identifier[Integer] operator[>] identifier[datediff] operator[SEP] identifier[DatePart] identifier[unit] , identifier[DateExpression] operator[<] identifier[D] operator...
@Override public StorePath uploadImageAndCrtThumbImage(InputStream inputStream, long fileSize, String fileExtName, Set<MetaData> metaDataSet) { FastImageFile fas...
class class_name[name] begin[{] method[uploadImageAndCrtThumbImage, return_type[type[StorePath]], modifier[public], parameter[inputStream, fileSize, fileExtName, metaDataSet]] begin[{] local_variable[type[FastImageFile], fastImageFile] if[binary_operation[literal[null], ==, member[.meta...
annotation[@] identifier[Override] Keyword[public] identifier[StorePath] identifier[uploadImageAndCrtThumbImage] operator[SEP] identifier[InputStream] identifier[inputStream] , Keyword[long] identifier[fileSize] , identifier[String] identifier[fileExtName] , identifier[Set] operator[<] identifier[MetaData] operator[...
protected Vec4 computeSurfacePoint(OrbitView view, Angle heading, Angle pitch) { Globe globe = wwd.getModel().getGlobe(); // Compute transform to be applied to north pointing Y so that it would point in the view direction // Move coordinate system to view center point Matrix transfor...
class class_name[name] begin[{] method[computeSurfacePoint, return_type[type[Vec4]], modifier[protected], parameter[view, heading, pitch]] begin[{] local_variable[type[Globe], globe] local_variable[type[Matrix], transform] assign[member[.transform], call[transform.multiply, para...
Keyword[protected] identifier[Vec4] identifier[computeSurfacePoint] operator[SEP] identifier[OrbitView] identifier[view] , identifier[Angle] identifier[heading] , identifier[Angle] identifier[pitch] operator[SEP] { identifier[Globe] identifier[globe] operator[=] identifier[wwd] operator[SEP] identifier[getMode...
private void handleWebSocketReplyMessage(final String webSocketText) { final List<Message<Object>> messages = QBit.factory().createProtocolParser().parse("", webSocketText); //noinspection Convert2streamapi for (Message<Object> message : messages) { if (message instanceof Respons...
class class_name[name] begin[{] method[handleWebSocketReplyMessage, return_type[void], modifier[private], parameter[webSocketText]] begin[{] local_variable[type[List], messages] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReferen...
Keyword[private] Keyword[void] identifier[handleWebSocketReplyMessage] operator[SEP] Keyword[final] identifier[String] identifier[webSocketText] operator[SEP] { Keyword[final] identifier[List] operator[<] identifier[Message] operator[<] identifier[Object] operator[>] operator[>] identifier[messages] operator[=] ...
private void putId() { // note: name and info may be null super.put("Provider.id name", String.valueOf(name)); super.put("Provider.id version", String.valueOf(version)); super.put("Provider.id info", String.valueOf(info)); super.put("Provider.id className", this.getClass().getNam...
class class_name[name] begin[{] method[putId, return_type[void], modifier[private], parameter[]] begin[{] SuperMethodInvocation(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value="Provider.id name"), MethodInvocation(arguments=[MemberReference(memb...
Keyword[private] Keyword[void] identifier[putId] operator[SEP] operator[SEP] { Keyword[super] operator[SEP] identifier[put] operator[SEP] literal[String] , identifier[String] operator[SEP] identifier[valueOf] operator[SEP] identifier[name] operator[SEP] operator[SEP] operator[SEP] Keyword[super] operator[SEP] i...
public static final boolean isNull(final String value, final boolean trim, final boolean empty) { // For backwards compatibility if (disableIsNull) return false; // No value? if (value == null) return true; // Trim the text when requested String trimmed = trim ? ...
class class_name[name] begin[{] method[isNull, return_type[type[boolean]], modifier[final public static], parameter[value, trim, empty]] begin[{] if[member[.disableIsNull]] begin[{] return[literal[false]] else begin[{] None end[}] if[binary_operation[member[.valu...
Keyword[public] Keyword[static] Keyword[final] Keyword[boolean] identifier[isNull] operator[SEP] Keyword[final] identifier[String] identifier[value] , Keyword[final] Keyword[boolean] identifier[trim] , Keyword[final] Keyword[boolean] identifier[empty] operator[SEP] { Keyword[if] operator[SEP] identifier[disabl...
@Override public java.util.Iterator<com.google.api.ads.adwords.axis.v201809.cm.AdGroupFeed> iterator() { if (entries == null) { return java.util.Collections.<com.google.api.ads.adwords.axis.v201809.cm.AdGroupFeed>emptyIterator(); } return java.util.Arrays.<com.google.api.ads.adwo...
class class_name[name] begin[{] method[iterator, return_type[type[java]], modifier[public], parameter[]] begin[{] if[binary_operation[member[.entries], ==, literal[null]]] begin[{] return[call[java.util.Collections, parameter[]]] else begin[{] None end[}] ret...
annotation[@] identifier[Override] Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[Iterator] operator[<] identifier[com] operator[SEP] identifier[google] operator[SEP] identifier[api] operator[SEP] identifier[ads] operator[SEP] identifier[adwords] operator[SEP] identifier[axis] ...
@Override public <T> T onlyOne(Class<T> serviceClass) { Collection<T> all = all(serviceClass); if (all.size() == 1) { return all.iterator().next(); } if (all.size() > 1) { throw new IllegalStateException( "Multiple service implementations found...
class class_name[name] begin[{] method[onlyOne, return_type[type[T]], modifier[public], parameter[serviceClass]] begin[{] local_variable[type[Collection], all] if[binary_operation[call[all.size, parameter[]], ==, literal[1]]] begin[{] return[call[all.iterator, parameter[]]] ...
annotation[@] identifier[Override] Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[onlyOne] operator[SEP] identifier[Class] operator[<] identifier[T] operator[>] identifier[serviceClass] operator[SEP] { identifier[Collection] operator[<] identifier[T] operator[>] identifier[all] op...
@SuppressWarnings("unchecked") @Override public EList<String> getElectronicMailAddresses() { return (EList<String>) eGet(Ifc4Package.Literals.IFC_TELECOM_ADDRESS__ELECTRONIC_MAIL_ADDRESSES, true); }
class class_name[name] begin[{] method[getElectronicMailAddresses, return_type[type[EList]], modifier[public], parameter[]] begin[{] return[Cast(expression=MethodInvocation(arguments=[MemberReference(member=IFC_TELECOM_ADDRESS__ELECTRONIC_MAIL_ADDRESSES, postfix_operators=[], prefix_operators=[], quali...
annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] annotation[@] identifier[Override] Keyword[public] identifier[EList] operator[<] identifier[String] operator[>] identifier[getElectronicMailAddresses] operator[SEP] operator[SEP] { Keyword[return] operator[SEP] identifier[ELis...
public FeatureInfoWithActions getFeatureInfoWidgetWithActions(MapPresenter mapPresenter) { FeatureInfoWithActions widgetWithActions = new FeatureInfoWithActions(); widgetWithActions.addHasFeature(new ZoomToObjectAction(mapPresenter)); return widgetWithActions; }
class class_name[name] begin[{] method[getFeatureInfoWidgetWithActions, return_type[type[FeatureInfoWithActions]], modifier[public], parameter[mapPresenter]] begin[{] local_variable[type[FeatureInfoWithActions], widgetWithActions] call[widgetWithActions.addHasFeature, parameter[ClassCre...
Keyword[public] identifier[FeatureInfoWithActions] identifier[getFeatureInfoWidgetWithActions] operator[SEP] identifier[MapPresenter] identifier[mapPresenter] operator[SEP] { identifier[FeatureInfoWithActions] identifier[widgetWithActions] operator[=] Keyword[new] identifier[FeatureInfoWithActions] operator[SEP]...
@Pure public static String getUserHomeDirectoryName() { final String userHome = System.getProperty("user.home"); //$NON-NLS-1$ if ((userHome == null || userHome.isEmpty()) && (OperatingSystem.ANDROID.isCurrentOS())) { return join(File.listRoots()[0], Android.HOME_DIRECTORY).toString(); } return userHome; }
class class_name[name] begin[{] method[getUserHomeDirectoryName, return_type[type[String]], modifier[public static], parameter[]] begin[{] local_variable[type[String], userHome] if[binary_operation[binary_operation[binary_operation[member[.userHome], ==, literal[null]], ||, call[userHom...
annotation[@] identifier[Pure] Keyword[public] Keyword[static] identifier[String] identifier[getUserHomeDirectoryName] operator[SEP] operator[SEP] { Keyword[final] identifier[String] identifier[userHome] operator[=] identifier[System] operator[SEP] identifier[getProperty] operator[SEP] literal[String] operator[S...
public static boolean hasFilter(Filter filter) { Jenkins j = Jenkins.getInstanceOrNull(); PluginServletFilter container = null; if(j != null) { container = getInstance(j.servletContext); } if (j == null || container == null) { return LEGACY.contains(filter...
class class_name[name] begin[{] method[hasFilter, return_type[type[boolean]], modifier[public static], parameter[filter]] begin[{] local_variable[type[Jenkins], j] local_variable[type[PluginServletFilter], container] if[binary_operation[member[.j], !=, literal[null]]] begin[{] ...
Keyword[public] Keyword[static] Keyword[boolean] identifier[hasFilter] operator[SEP] identifier[Filter] identifier[filter] operator[SEP] { identifier[Jenkins] identifier[j] operator[=] identifier[Jenkins] operator[SEP] identifier[getInstanceOrNull] operator[SEP] operator[SEP] operator[SEP] identifier[PluginServl...
public int getLength() { int length = 0; Iterator<V> it = this.values().iterator(); while (it.hasNext()) { length += ((ID3v2Frame) it.next()).getFrameLength(); } return length; }
class class_name[name] begin[{] method[getLength, return_type[type[int]], modifier[public], parameter[]] begin[{] local_variable[type[int], length] local_variable[type[Iterator], it] while[call[it.hasNext, parameter[]]] begin[{] assign[member[.length], Ca...
Keyword[public] Keyword[int] identifier[getLength] operator[SEP] operator[SEP] { Keyword[int] identifier[length] operator[=] Other[0] operator[SEP] identifier[Iterator] operator[<] identifier[V] operator[>] identifier[it] operator[=] Keyword[this] operator[SEP] identifier[values] operator[SEP] operator[SEP] oper...
public PhotoList<Photo> getPhotos(String photosetId, int perPage, int page) throws FlickrException { return getPhotos(photosetId, Extras.MIN_EXTRAS, Flickr.PRIVACY_LEVEL_NO_FILTER, perPage, page); }
class class_name[name] begin[{] method[getPhotos, return_type[type[PhotoList]], modifier[public], parameter[photosetId, perPage, page]] begin[{] return[call[.getPhotos, parameter[member[.photosetId], member[Extras.MIN_EXTRAS], member[Flickr.PRIVACY_LEVEL_NO_FILTER], member[.perPage], member[.page]]]] ...
Keyword[public] identifier[PhotoList] operator[<] identifier[Photo] operator[>] identifier[getPhotos] operator[SEP] identifier[String] identifier[photosetId] , Keyword[int] identifier[perPage] , Keyword[int] identifier[page] operator[SEP] Keyword[throws] identifier[FlickrException] { Keyword[return] identifier...
@UiHandler("m_includeExpiredCheckBox") protected void onIncludeExpiredChange(ValueChangeEvent<Boolean> event) { Boolean value = event.getValue(); m_tabHandler.setIncludeExpired(value.booleanValue(), true); }
class class_name[name] begin[{] method[onIncludeExpiredChange, return_type[void], modifier[protected], parameter[event]] begin[{] local_variable[type[Boolean], value] call[m_tabHandler.setIncludeExpired, parameter[call[value.booleanValue, parameter[]], literal[true]]] end[}] END[}]
annotation[@] identifier[UiHandler] operator[SEP] literal[String] operator[SEP] Keyword[protected] Keyword[void] identifier[onIncludeExpiredChange] operator[SEP] identifier[ValueChangeEvent] operator[<] identifier[Boolean] operator[>] identifier[event] operator[SEP] { identifier[Boolean] identifier[value] operat...
public static boolean isJavaAtLeast(double version) { String javaVersion = System.getProperty("java.version"); if (javaVersion == null) { return false; } // if the retrieved version is one three digits, remove the last one. Matcher matcher = JAVA_VERSION.matcher(java...
class class_name[name] begin[{] method[isJavaAtLeast, return_type[type[boolean]], modifier[public static], parameter[version]] begin[{] local_variable[type[String], javaVersion] if[binary_operation[member[.javaVersion], ==, literal[null]]] begin[{] return[literal[false]] ...
Keyword[public] Keyword[static] Keyword[boolean] identifier[isJavaAtLeast] operator[SEP] Keyword[double] identifier[version] operator[SEP] { identifier[String] identifier[javaVersion] operator[=] identifier[System] operator[SEP] identifier[getProperty] operator[SEP] literal[String] operator[SEP] operator[SEP] Ke...
public static <R> Stream<R> zip(final short[] a, final short[] b, final short[] c, final ShortTriFunction<R> zipFunction) { return zip(ShortIteratorEx.of(a), ShortIteratorEx.of(b), ShortIteratorEx.of(c), zipFunction); }
class class_name[name] begin[{] method[zip, return_type[type[Stream]], modifier[public static], parameter[a, b, c, zipFunction]] begin[{] return[call[.zip, parameter[call[ShortIteratorEx.of, parameter[member[.a]]], call[ShortIteratorEx.of, parameter[member[.b]]], call[ShortIteratorEx.of, parameter[memb...
Keyword[public] Keyword[static] operator[<] identifier[R] operator[>] identifier[Stream] operator[<] identifier[R] operator[>] identifier[zip] operator[SEP] Keyword[final] Keyword[short] operator[SEP] operator[SEP] identifier[a] , Keyword[final] Keyword[short] operator[SEP] operator[SEP] identifier[b] , Keyword[final...
@SuppressWarnings("unchecked") public static <T extends StatefulConnection<?, ?>> GenericObjectPool<T> createGenericObjectPool( Supplier<T> connectionSupplier, GenericObjectPoolConfig<T> config, boolean wrapConnections) { LettuceAssert.notNull(connectionSupplier, "Connection supplier must not b...
class class_name[name] begin[{] method[createGenericObjectPool, return_type[type[GenericObjectPool]], modifier[public static], parameter[connectionSupplier, config, wrapConnections]] begin[{] call[LettuceAssert.notNull, parameter[member[.connectionSupplier], literal["Connection supplier must no...
annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[StatefulConnection] operator[<] operator[?] , operator[?] operator[>] operator[>] identifier[GenericObjectPool] operator[<] identifier[T] operator...
private void parseDocument() throws Exception { try { // added by MHK boolean sawDTD = parseProlog(); require('<'); parseElement(!sawDTD); } catch (EOFException ee) { // added by MHK fatal("premature end of file", "[EOF]", null); } try { ...
class class_name[name] begin[{] method[parseDocument, return_type[void], modifier[private], parameter[]] begin[{] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[], member=parseProlog, postfix_operators=...
Keyword[private] Keyword[void] identifier[parseDocument] operator[SEP] operator[SEP] Keyword[throws] identifier[Exception] { Keyword[try] { Keyword[boolean] identifier[sawDTD] operator[=] identifier[parseProlog] operator[SEP] operator[SEP] operator[SEP] identifier[require] operator[SEP] literal[String...
private Response<SearchResult> searchForServiceById(final Long id) throws LdapException { val filter = LdapUtils.newLdaptiveSearchFilter(this.searchFilter, LdapUtils.LDAP_SEARCH_FILTER_DEFAULT_PARAM_NAME, CollectionUtils.wrap(id.toString())); return LdapUtils.executeSearchOperation(this.conn...
class class_name[name] begin[{] method[searchForServiceById, return_type[type[Response]], modifier[private], parameter[id]] begin[{] local_variable[type[val], filter] return[call[LdapUtils.executeSearchOperation, parameter[THIS[member[None.connectionFactory]], THIS[member[None.baseDn]], member[...
Keyword[private] identifier[Response] operator[<] identifier[SearchResult] operator[>] identifier[searchForServiceById] operator[SEP] Keyword[final] identifier[Long] identifier[id] operator[SEP] Keyword[throws] identifier[LdapException] { identifier[val] identifier[filter] operator[=] identifier[LdapUtils] opera...
public boolean isSupported(Jid jid) throws SmackException, XMPPException, InterruptedException { return ServiceDiscoveryManager.getInstanceFor(connection()).supportsFeature(jid, DeliveryReceipt.NAMESPACE); }
class class_name[name] begin[{] method[isSupported, return_type[type[boolean]], modifier[public], parameter[jid]] begin[{] return[call[ServiceDiscoveryManager.getInstanceFor, parameter[call[.connection, parameter[]]]]] end[}] END[}]
Keyword[public] Keyword[boolean] identifier[isSupported] operator[SEP] identifier[Jid] identifier[jid] operator[SEP] Keyword[throws] identifier[SmackException] , identifier[XMPPException] , identifier[InterruptedException] { Keyword[return] identifier[ServiceDiscoveryManager] operator[SEP] identifier[getInstan...
static long calcInterval(int segments, int start, int limit) { long range = limit - start; if (range < 0) { return 0; } int partSegment = (range % segments) == 0 ? 0 : 1; return (range / segments) + partSegment; ...
class class_name[name] begin[{] method[calcInterval, return_type[type[long]], modifier[static], parameter[segments, start, limit]] begin[{] local_variable[type[long], range] if[binary_operation[member[.range], <, literal[0]]] begin[{] return[literal[0]] else begin[{]...
Keyword[static] Keyword[long] identifier[calcInterval] operator[SEP] Keyword[int] identifier[segments] , Keyword[int] identifier[start] , Keyword[int] identifier[limit] operator[SEP] { Keyword[long] identifier[range] operator[=] identifier[limit] operator[-] identifier[start] operator[SEP] Keyword[if] operator...
private void loadBodyRows(final SheetConfiguration sheetConfig, final Map<String, CellRangeAddress> cellRangeMap, final List<String> skippedRegionCells) { int top = sheetConfig.getBodyCellRange().getTopRow(); int bottom = CellUtility.getBodyBottomFromConfig(sheetConfig); int left = sheetConfig.getBodyCel...
class class_name[name] begin[{] method[loadBodyRows, return_type[void], modifier[private], parameter[sheetConfig, cellRangeMap, skippedRegionCells]] begin[{] local_variable[type[int], top] local_variable[type[int], bottom] local_variable[type[int], left] local_variable[type[int]...
Keyword[private] Keyword[void] identifier[loadBodyRows] operator[SEP] Keyword[final] identifier[SheetConfiguration] identifier[sheetConfig] , Keyword[final] identifier[Map] operator[<] identifier[String] , identifier[CellRangeAddress] operator[>] identifier[cellRangeMap] , Keyword[final] identifier[List] operator[<]...
@Deprecated public static List<String> qualityList(Enumeration<String> e) { if (e == null || !e.hasMoreElements()) return Collections.emptyList(); QuotedQualityCSV values = new QuotedQualityCSV(); while (e.hasMoreElements()) values.addValue(e.nextElement()); ...
class class_name[name] begin[{] method[qualityList, return_type[type[List]], modifier[public static], parameter[e]] begin[{] if[binary_operation[binary_operation[member[.e], ==, literal[null]], ||, call[e.hasMoreElements, parameter[]]]] begin[{] return[call[Collections.emptyList, parameter[]]] ...
annotation[@] identifier[Deprecated] Keyword[public] Keyword[static] identifier[List] operator[<] identifier[String] operator[>] identifier[qualityList] operator[SEP] identifier[Enumeration] operator[<] identifier[String] operator[>] identifier[e] operator[SEP] { Keyword[if] operator[SEP] identifier[e] operator[...
private static String blankToNull(String value) { if (value != null) { value = value.trim(); if (value.equals("")) { value = null; } } return value; }
class class_name[name] begin[{] method[blankToNull, return_type[type[String]], modifier[private static], parameter[value]] begin[{] if[binary_operation[member[.value], !=, literal[null]]] begin[{] assign[member[.value], call[value.trim, parameter[]]] ...
Keyword[private] Keyword[static] identifier[String] identifier[blankToNull] operator[SEP] identifier[String] identifier[value] operator[SEP] { Keyword[if] operator[SEP] identifier[value] operator[!=] Other[null] operator[SEP] { identifier[value] operator[=] identifier[value] operator[SEP] identifier[t...
@Override public void audit(final LoggingEvent e) { try { logger.info(MarkerFactory.getMarker(AUDIT), serialize(e)); } catch (Exception ex) { throw new RuntimeException("unable to serialize event", ex); } }
class class_name[name] begin[{] method[audit, return_type[void], modifier[public], parameter[e]] begin[{] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[MemberReference(member=AUDIT, postfix_operators=[], prefix_operators=[], qualifier=, selec...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[audit] operator[SEP] Keyword[final] identifier[LoggingEvent] identifier[e] operator[SEP] { Keyword[try] { identifier[logger] operator[SEP] identifier[info] operator[SEP] identifier[MarkerFactory] operator[SEP] identifier[getMa...
public static InterfaceMeta get(final Class<?> type) { InterfaceMeta interfaceMeta = INTERFACE_MAP.get(type); if (interfaceMeta == null) { final Interface waylandInterface = type.getAnnotation(Interface.class); if (waylandInterface == null) { interfaceMeta = NO_IN...
class class_name[name] begin[{] method[get, return_type[type[InterfaceMeta]], modifier[public static], parameter[type]] begin[{] local_variable[type[InterfaceMeta], interfaceMeta] if[binary_operation[member[.interfaceMeta], ==, literal[null]]] begin[{] local_variable[type[In...
Keyword[public] Keyword[static] identifier[InterfaceMeta] identifier[get] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] operator[>] identifier[type] operator[SEP] { identifier[InterfaceMeta] identifier[interfaceMeta] operator[=] identifier[INTERFACE_MAP] operator[SEP] identifier[get] ope...
public static Response patch(String path, Object... pathParams) { return given().patch(path, pathParams); }
class class_name[name] begin[{] method[patch, return_type[type[Response]], modifier[public static], parameter[path, pathParams]] begin[{] return[call[.given, parameter[]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[Response] identifier[patch] operator[SEP] identifier[String] identifier[path] , identifier[Object] operator[...] identifier[pathParams] operator[SEP] { Keyword[return] identifier[given] operator[SEP] operator[SEP] operator[SEP] identifier[patch] operator[SEP] identifie...
public CalendarWeek minus(Years<Weekcycle> years) { if (years.isEmpty()) { return this; } int y = MathUtils.safeSubtract(this.year, years.getAmount()); int effectiveWeek = this.week; if ((this.week == 53) && (maximumOfWeek(y) < 53)) { effectiveWeek = 52...
class class_name[name] begin[{] method[minus, return_type[type[CalendarWeek]], modifier[public], parameter[years]] begin[{] if[call[years.isEmpty, parameter[]]] begin[{] return[THIS[]] else begin[{] None end[}] local_variable[type[int], y] local_varia...
Keyword[public] identifier[CalendarWeek] identifier[minus] operator[SEP] identifier[Years] operator[<] identifier[Weekcycle] operator[>] identifier[years] operator[SEP] { Keyword[if] operator[SEP] identifier[years] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] { Keyword[r...
@SuppressWarnings("PMD.NPathComplexity") private static boolean isConfigured(AuditType auditType, JSONArray jsonArray) { if (auditType.equals(AuditType.CODE_REVIEW)) { return (jsonArray.toJSONString().contains(DashboardAuditStatus.DASHBOARD_REPO_CONFIGURED.name()) ? true : false); } ...
class class_name[name] begin[{] method[isConfigured, return_type[type[boolean]], modifier[private static], parameter[auditType, jsonArray]] begin[{] if[call[auditType.equals, parameter[member[AuditType.CODE_REVIEW]]]] begin[{] return[TernaryExpression(condition=MethodInvocation(argu...
annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[private] Keyword[static] Keyword[boolean] identifier[isConfigured] operator[SEP] identifier[AuditType] identifier[auditType] , identifier[JSONArray] identifier[jsonArray] operator[SEP] { Keyword[if] operator[SEP] iden...
public SDVariable pad(SDVariable input, SDVariable padding, double constant){ return pad(null, input, padding, Pad.Mode.CONSTANT, constant); }
class class_name[name] begin[{] method[pad, return_type[type[SDVariable]], modifier[public], parameter[input, padding, constant]] begin[{] return[call[.pad, parameter[literal[null], member[.input], member[.padding], member[Pad.Mode.CONSTANT], member[.constant]]]] end[}] END[}]
Keyword[public] identifier[SDVariable] identifier[pad] operator[SEP] identifier[SDVariable] identifier[input] , identifier[SDVariable] identifier[padding] , Keyword[double] identifier[constant] operator[SEP] { Keyword[return] identifier[pad] operator[SEP] Other[null] , identifier[input] , identifier[padding]...
@NonNull public static Disposable fromSubscription(@NonNull Subscription subscription) { ObjectHelper.requireNonNull(subscription, "subscription is null"); return new SubscriptionDisposable(subscription); }
class class_name[name] begin[{] method[fromSubscription, return_type[type[Disposable]], modifier[public static], parameter[subscription]] begin[{] call[ObjectHelper.requireNonNull, parameter[member[.subscription], literal["subscription is null"]]] return[ClassCreator(arguments=[MemberRe...
annotation[@] identifier[NonNull] Keyword[public] Keyword[static] identifier[Disposable] identifier[fromSubscription] operator[SEP] annotation[@] identifier[NonNull] identifier[Subscription] identifier[subscription] operator[SEP] { identifier[ObjectHelper] operator[SEP] identifier[requireNonNull] operator[SEP] i...
public <T extends Serializable, Method extends BotApiMethod<T>, Callback extends SentCallback<T>> void executeAsync(Method method, Callback callback) throws TelegramApiException { if (method == null) { throw new TelegramApiException("Parameter method can not be null"); } if (callback...
class class_name[name] begin[{] method[executeAsync, return_type[void], modifier[public], parameter[method, callback]] begin[{] if[binary_operation[member[.method], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_op...
Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[Serializable] , identifier[Method] Keyword[extends] identifier[BotApiMethod] operator[<] identifier[T] operator[>] , identifier[Callback] Keyword[extends] identifier[SentCallback] operator[<] identifier[T] operator[>] operator[>] Keyword[void] iden...
public Collection<ProcessDefinition> getProcessesByDeploymentId(String deploymentId, QueryContext queryContext) { deploymentId = getLatestDeploymentId(requireNonNull(deploymentId, DEPLOYMENT_ID_MUST_NOT_BE_NULL)); List<ProcessDefinition> outputCollection = new ArrayList<ProcessDefinition>(); Colle...
class class_name[name] begin[{] method[getProcessesByDeploymentId, return_type[type[Collection]], modifier[public], parameter[deploymentId, queryContext]] begin[{] assign[member[.deploymentId], call[.getLatestDeploymentId, parameter[call[.requireNonNull, parameter[member[.deploymentId], member[...
Keyword[public] identifier[Collection] operator[<] identifier[ProcessDefinition] operator[>] identifier[getProcessesByDeploymentId] operator[SEP] identifier[String] identifier[deploymentId] , identifier[QueryContext] identifier[queryContext] operator[SEP] { identifier[deploymentId] operator[=] identifier[getLat...
protected MessageFormat createMessageFormat(String msg, Locale locale) { return new MessageFormat((msg != null ? msg : ""), locale); }
class class_name[name] begin[{] method[createMessageFormat, return_type[type[MessageFormat]], modifier[protected], parameter[msg, locale]] begin[{] return[ClassCreator(arguments=[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=msg, postfix_operators=[], prefix_operators=[], ...
Keyword[protected] identifier[MessageFormat] identifier[createMessageFormat] operator[SEP] identifier[String] identifier[msg] , identifier[Locale] identifier[locale] operator[SEP] { Keyword[return] Keyword[new] identifier[MessageFormat] operator[SEP] operator[SEP] identifier[msg] operator[!=] Other[null] operat...
public static void waitForStandalone(final Process process, final ModelControllerClient client, final long startupTimeout) throws InterruptedException, RuntimeException, TimeoutException { Assert.checkNotNullParam("client", client); long timeout = startupTimeout * 1000; final long sl...
class class_name[name] begin[{] method[waitForStandalone, return_type[void], modifier[public static], parameter[process, client, startupTimeout]] begin[{] call[Assert.checkNotNullParam, parameter[literal["client"], member[.client]]] local_variable[type[long], timeout] local_vari...
Keyword[public] Keyword[static] Keyword[void] identifier[waitForStandalone] operator[SEP] Keyword[final] identifier[Process] identifier[process] , Keyword[final] identifier[ModelControllerClient] identifier[client] , Keyword[final] Keyword[long] identifier[startupTimeout] operator[SEP] Keyword[throws] identifier[Inte...
@Override public void index(Class entityClazz, EntityMetadata metadata, Map<String, Object> values, Object parentId, Class parentClazz) { ObjectMapper mapper = new ObjectMapper(); try { values.put("entity_class", metadata.getEntityClazz().getCanonicalName().toLowe...
class class_name[name] begin[{] method[index, return_type[void], modifier[public], parameter[entityClazz, metadata, values, parentId, parentClazz]] begin[{] local_variable[type[ObjectMapper], mapper] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[Literal(postfix_...
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[index] operator[SEP] identifier[Class] identifier[entityClazz] , identifier[EntityMetadata] identifier[metadata] , identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[values] , identifier[Object] ident...
public static String render(String templateContent, Map<String, Object> paramMap) { StringWriter writer = new StringWriter(); try { Configuration cfg = new Configuration(Configuration.VERSION_2_3_22); cfg.setTemplateLoader(new StringTemplateLoader(templateContent)); c...
class class_name[name] begin[{] method[render, return_type[type[String]], modifier[public static], parameter[templateContent, paramMap]] begin[{] local_variable[type[StringWriter], writer] TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[]...
Keyword[public] Keyword[static] identifier[String] identifier[render] operator[SEP] identifier[String] identifier[templateContent] , identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[paramMap] operator[SEP] { identifier[StringWriter] identifier[writer] operator[=] Keywo...
public Pager<Group> getGroups(int itemsPerPage) throws GitLabApiException { return (new Pager<Group>(this, Group.class, itemsPerPage, null, "groups")); }
class class_name[name] begin[{] method[getGroups, return_type[type[Pager]], modifier[public], parameter[itemsPerPage]] begin[{] return[ClassCreator(arguments=[This(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[]), ClassReference(postfix_operators=[], prefix_operators=[], qualifi...
Keyword[public] identifier[Pager] operator[<] identifier[Group] operator[>] identifier[getGroups] operator[SEP] Keyword[int] identifier[itemsPerPage] operator[SEP] Keyword[throws] identifier[GitLabApiException] { Keyword[return] operator[SEP] Keyword[new] identifier[Pager] operator[<] identifier[Group] operator[...
private static void analyzeClassFile(org.jacoco.previous.core.analysis.Analyzer analyzer, File classFile) { try (InputStream inputStream = new FileInputStream(classFile)) { analyzer.analyzeClass(inputStream, classFile.getPath()); } catch (IOException e) { // (Godin): in fact JaCoCo includes name int...
class class_name[name] begin[{] method[analyzeClassFile, return_type[void], modifier[private static], parameter[analyzer, classFile]] begin[{] TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=inputStream, postfix_operators=[], prefix_operators=[], qu...
Keyword[private] Keyword[static] Keyword[void] identifier[analyzeClassFile] operator[SEP] identifier[org] operator[SEP] identifier[jacoco] operator[SEP] identifier[previous] operator[SEP] identifier[core] operator[SEP] identifier[analysis] operator[SEP] identifier[Analyzer] identifier[analyzer] , identifier[File] iden...
public <T extends IGeneratorParameter<S>, S> S getDefault(Class<T> param) { if (renderingParameters.containsKey(param.getName())) return getParameter(param).getDefault(); // OK, this parameter is not registered, but that's fine, as we are // only to return the default value anyway... tr...
class class_name[name] begin[{] method[getDefault, return_type[type[S]], modifier[public], parameter[param]] begin[{] if[call[renderingParameters.containsKey, parameter[call[param.getName, parameter[]]]]] begin[{] return[call[.getParameter, parameter[member[.param]]]] else begin[{] None...
Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[IGeneratorParameter] operator[<] identifier[S] operator[>] , identifier[S] operator[>] identifier[S] identifier[getDefault] operator[SEP] identifier[Class] operator[<] identifier[T] operator[>] identifier[param] operator[SEP] { Keyword[if] op...
private void updateUnderFileSystemInputStream(long offset) throws IOException { if ((mUnderFileSystemInputStream != null) && offset != mInStreamPos) { mUfsInstreamManager.release(mUnderFileSystemInputStream); mUnderFileSystemInputStream = null; mInStreamPos = -1; } if (mUnderFileSystemInp...
class class_name[name] begin[{] method[updateUnderFileSystemInputStream, return_type[void], modifier[private], parameter[offset]] begin[{] if[binary_operation[binary_operation[member[.mUnderFileSystemInputStream], !=, literal[null]], &&, binary_operation[member[.offset], !=, member[.mInStreamPo...
Keyword[private] Keyword[void] identifier[updateUnderFileSystemInputStream] operator[SEP] Keyword[long] identifier[offset] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[if] operator[SEP] operator[SEP] identifier[mUnderFileSystemInputStream] operator[!=] Other[null] operator[SEP] operator[&&] id...
public com.google.api.ads.adwords.axis.v201809.cm.Image getLandscapeLogoImage() { return landscapeLogoImage; }
class class_name[name] begin[{] method[getLandscapeLogoImage, return_type[type[com]], modifier[public], parameter[]] begin[{] return[member[.landscapeLogoImage]] end[}] END[}]
Keyword[public] identifier[com] operator[SEP] identifier[google] operator[SEP] identifier[api] operator[SEP] identifier[ads] operator[SEP] identifier[adwords] operator[SEP] identifier[axis] operator[SEP] identifier[v201809] operator[SEP] identifier[cm] operator[SEP] identifier[Image] identifier[getLandscapeLogoImage] o...
public void marshall(DeleteDirectoryRequest deleteDirectoryRequest, ProtocolMarshaller protocolMarshaller) { if (deleteDirectoryRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(deleteDirecto...
class class_name[name] begin[{] method[marshall, return_type[void], modifier[public], parameter[deleteDirectoryRequest, protocolMarshaller]] begin[{] if[binary_operation[member[.deleteDirectoryRequest], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[L...
Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[DeleteDirectoryRequest] identifier[deleteDirectoryRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] { Keyword[if] operator[SEP] identifier[deleteDirectoryRequest] operator[==] Other[null] operator[SE...
private CmsXmlContent getContentDocument(CmsFile file, boolean fromCache) throws CmsXmlException { CmsXmlContent content = null; if (fromCache) { content = getSessionCache().getCacheXmlContent(file.getStructureId()); } if (content == null) { content = CmsXmlConte...
class class_name[name] begin[{] method[getContentDocument, return_type[type[CmsXmlContent]], modifier[private], parameter[file, fromCache]] begin[{] local_variable[type[CmsXmlContent], content] if[member[.fromCache]] begin[{] assign[member[.content], call[.getSes...
Keyword[private] identifier[CmsXmlContent] identifier[getContentDocument] operator[SEP] identifier[CmsFile] identifier[file] , Keyword[boolean] identifier[fromCache] operator[SEP] Keyword[throws] identifier[CmsXmlException] { identifier[CmsXmlContent] identifier[content] operator[=] Other[null] operator[SEP] Ke...
public OvhOrder cdn_webstorage_serviceName_traffic_POST(String serviceName, OvhOrderTrafficEnum bandwidth) throws IOException { String qPath = "/order/cdn/webstorage/{serviceName}/traffic"; StringBuilder sb = path(qPath, serviceName); HashMap<String, Object>o = new HashMap<String, Object>(); addBody(o, "bandwid...
class class_name[name] begin[{] method[cdn_webstorage_serviceName_traffic_POST, return_type[type[OvhOrder]], modifier[public], parameter[serviceName, bandwidth]] begin[{] local_variable[type[String], qPath] local_variable[type[StringBuilder], sb] local_variable[type[HashMap], o] ...
Keyword[public] identifier[OvhOrder] identifier[cdn_webstorage_serviceName_traffic_POST] operator[SEP] identifier[String] identifier[serviceName] , identifier[OvhOrderTrafficEnum] identifier[bandwidth] operator[SEP] Keyword[throws] identifier[IOException] { identifier[String] identifier[qPath] operator[=] liter...
private static List<String> parseExecParameters(String paramText) { final String SafeParamStringValuePattern = "#(SQL_PARSER_SAFE_PARAMSTRING)"; // Find all quoted strings. // Mask out strings that contain whitespace or commas // that must not be confused with parameter separators. ...
class class_name[name] begin[{] method[parseExecParameters, return_type[type[List]], modifier[private static], parameter[paramText]] begin[{] local_variable[type[String], SafeParamStringValuePattern] local_variable[type[ArrayList], originalString] local_variable[type[Matcher], stringMat...
Keyword[private] Keyword[static] identifier[List] operator[<] identifier[String] operator[>] identifier[parseExecParameters] operator[SEP] identifier[String] identifier[paramText] operator[SEP] { Keyword[final] identifier[String] identifier[SafeParamStringValuePattern] operator[=] literal[String] operator[SEP] i...
void shutdown() throws InterruptedException { m_shouldStop = true; if (m_thread != null) { m_selector.wakeup(); m_thread.join(); } }
class class_name[name] begin[{] method[shutdown, return_type[void], modifier[default], parameter[]] begin[{] assign[member[.m_shouldStop], literal[true]] if[binary_operation[member[.m_thread], !=, literal[null]]] begin[{] call[m_selector.wakeup, parameter...
Keyword[void] identifier[shutdown] operator[SEP] operator[SEP] Keyword[throws] identifier[InterruptedException] { identifier[m_shouldStop] operator[=] literal[boolean] operator[SEP] Keyword[if] operator[SEP] identifier[m_thread] operator[!=] Other[null] operator[SEP] { identifier[m_selector] operator[...
public OvhTrafficExtract billingAccount_line_serviceName_trafficExtracts_id_GET(String billingAccount, String serviceName, Long id) throws IOException { String qPath = "/telephony/{billingAccount}/line/{serviceName}/trafficExtracts/{id}"; StringBuilder sb = path(qPath, billingAccount, serviceName, id); String res...
class class_name[name] begin[{] method[billingAccount_line_serviceName_trafficExtracts_id_GET, return_type[type[OvhTrafficExtract]], modifier[public], parameter[billingAccount, serviceName, id]] begin[{] local_variable[type[String], qPath] local_variable[type[StringBuilder], sb] local_v...
Keyword[public] identifier[OvhTrafficExtract] identifier[billingAccount_line_serviceName_trafficExtracts_id_GET] operator[SEP] identifier[String] identifier[billingAccount] , identifier[String] identifier[serviceName] , identifier[Long] identifier[id] operator[SEP] Keyword[throws] identifier[IOException] { ide...
public float similarity(K what, K with) { Vector vectorWhat = storage.get(what); if (vectorWhat == null) { return -1f; } Vector vectorWith = storage.get(with); if (vectorWith == null) { return -1f; } return vectorWhat.co...
class class_name[name] begin[{] method[similarity, return_type[type[float]], modifier[public], parameter[what, with]] begin[{] local_variable[type[Vector], vectorWhat] if[binary_operation[member[.vectorWhat], ==, literal[null]]] begin[{] return[literal[1f]] else begi...
Keyword[public] Keyword[float] identifier[similarity] operator[SEP] identifier[K] identifier[what] , identifier[K] identifier[with] operator[SEP] { identifier[Vector] identifier[vectorWhat] operator[=] identifier[storage] operator[SEP] identifier[get] operator[SEP] identifier[what] operator[SEP] operator[SEP] K...
public static String getParamInfo(Parameterizable p) { StringBuilder sb = new StringBuilder(p.getParameters().size() * 20); for (Parameter e : p.getParameters().values()) { if (e.getValue() != null && !e.getValue().equals(e.getDefault())) { sb.append(e.toString()).append("\n"); ...
class class_name[name] begin[{] method[getParamInfo, return_type[type[String]], modifier[public static], parameter[p]] begin[{] local_variable[type[StringBuilder], sb] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=BinaryOperation(operand...
Keyword[public] Keyword[static] identifier[String] identifier[getParamInfo] operator[SEP] identifier[Parameterizable] identifier[p] operator[SEP] { identifier[StringBuilder] identifier[sb] operator[=] Keyword[new] identifier[StringBuilder] operator[SEP] identifier[p] operator[SEP] identifier[getParameters] opera...
public static ModuleId fromString(String moduleId) throws IllegalArgumentException { if (moduleId == null) { throw new IllegalArgumentException("Module Id String is null"); } if (moduleId.length() == 0) { throw new IllegalArgumentException("Empty Module Id String"); ...
class class_name[name] begin[{] method[fromString, return_type[type[ModuleId]], modifier[public static], parameter[moduleId]] begin[{] if[binary_operation[member[.moduleId], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], ...
Keyword[public] Keyword[static] identifier[ModuleId] identifier[fromString] operator[SEP] identifier[String] identifier[moduleId] operator[SEP] Keyword[throws] identifier[IllegalArgumentException] { Keyword[if] operator[SEP] identifier[moduleId] operator[==] Other[null] operator[SEP] { Keyword[throw] ...
void validate(TableKelp table) { if (! table.isValidate()) { return; } Row row = table.row(); for (BlockLeaf block : _blocks) { block.validateBlock(row); } }
class class_name[name] begin[{] method[validate, return_type[void], modifier[default], parameter[table]] begin[{] if[call[table.isValidate, parameter[]]] begin[{] return[None] else begin[{] None end[}] local_variable[type[Row], row] ForStatement(body=...
Keyword[void] identifier[validate] operator[SEP] identifier[TableKelp] identifier[table] operator[SEP] { Keyword[if] operator[SEP] operator[!] identifier[table] operator[SEP] identifier[isValidate] operator[SEP] operator[SEP] operator[SEP] { Keyword[return] operator[SEP] } identifier[Row...
protected void copySelectionToClipboard(final MBasicTable table) { if (table.getSelectionModel().isSelectionEmpty()) { return; } final Toolkit toolkit = table.getToolkit(); final Clipboard clipboard = toolkit.getSystemClipboard(); final ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream...
class class_name[name] begin[{] method[copySelectionToClipboard, return_type[void], modifier[protected], parameter[table]] begin[{] if[call[table.getSelectionModel, parameter[]]] begin[{] return[None] else begin[{] None end[}] local_variable[type[Toolkit], to...
Keyword[protected] Keyword[void] identifier[copySelectionToClipboard] operator[SEP] Keyword[final] identifier[MBasicTable] identifier[table] operator[SEP] { Keyword[if] operator[SEP] identifier[table] operator[SEP] identifier[getSelectionModel] operator[SEP] operator[SEP] operator[SEP] identifier[isSelectionEmpt...
private void checkClockDrift(long intervalMillis) { long now = Clock.currentTimeMillis(); // compensate for any abrupt jumps forward in the system clock if (lastHeartbeat != 0L) { long clockJump = now - lastHeartbeat - intervalMillis; long absoluteClockJump = Math.abs(clo...
class class_name[name] begin[{] method[checkClockDrift, return_type[void], modifier[private], parameter[intervalMillis]] begin[{] local_variable[type[long], now] if[binary_operation[member[.lastHeartbeat], !=, literal[0L]]] begin[{] local_variable[type[long], clockJump] ...
Keyword[private] Keyword[void] identifier[checkClockDrift] operator[SEP] Keyword[long] identifier[intervalMillis] operator[SEP] { Keyword[long] identifier[now] operator[=] identifier[Clock] operator[SEP] identifier[currentTimeMillis] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[...
@Pure public static Element getElementFromPath(Node document, boolean caseSensitive, String... path) { assert document != null : AssertMessages.notNullParameter(0); return getElementFromPath(document, caseSensitive, 0, path); }
class class_name[name] begin[{] method[getElementFromPath, return_type[type[Element]], modifier[public static], parameter[document, caseSensitive, path]] begin[{] AssertStatement(condition=BinaryOperation(operandl=MemberReference(member=document, postfix_operators=[], prefix_operators=[], qualifier=, s...
annotation[@] identifier[Pure] Keyword[public] Keyword[static] identifier[Element] identifier[getElementFromPath] operator[SEP] identifier[Node] identifier[document] , Keyword[boolean] identifier[caseSensitive] , identifier[String] operator[...] identifier[path] operator[SEP] { Keyword[assert] identifier[docum...
@Override public UserTrades getTradeHistory(final TradeHistoryParams params) throws IOException { if (params instanceof RippleTradeHistoryCount) { final RippleTradeHistoryCount rippleParams = (RippleTradeHistoryCount) params; rippleParams.resetApiCallCount(); rippleParams.resetTradeCount(); ...
class class_name[name] begin[{] method[getTradeHistory, return_type[type[UserTrades]], modifier[public], parameter[params]] begin[{] if[binary_operation[member[.params], instanceof, type[RippleTradeHistoryCount]]] begin[{] local_variable[type[RippleTradeHistoryCount], rippleParams] ...
annotation[@] identifier[Override] Keyword[public] identifier[UserTrades] identifier[getTradeHistory] operator[SEP] Keyword[final] identifier[TradeHistoryParams] identifier[params] operator[SEP] Keyword[throws] identifier[IOException] { Keyword[if] operator[SEP] identifier[params] Keyword[instanceof] identifier[...
@Override public InternationalFixedDate date(int prolepticYear, int month, int dayOfMonth) { return InternationalFixedDate.of(prolepticYear, month, dayOfMonth); }
class class_name[name] begin[{] method[date, return_type[type[InternationalFixedDate]], modifier[public], parameter[prolepticYear, month, dayOfMonth]] begin[{] return[call[InternationalFixedDate.of, parameter[member[.prolepticYear], member[.month], member[.dayOfMonth]]]] end[}] END[}]
annotation[@] identifier[Override] Keyword[public] identifier[InternationalFixedDate] identifier[date] operator[SEP] Keyword[int] identifier[prolepticYear] , Keyword[int] identifier[month] , Keyword[int] identifier[dayOfMonth] operator[SEP] { Keyword[return] identifier[InternationalFixedDate] operator[SEP] ide...
public static File zip(String srcPath, String zipPath) throws UtilException { return zip(srcPath, zipPath, false); }
class class_name[name] begin[{] method[zip, return_type[type[File]], modifier[public static], parameter[srcPath, zipPath]] begin[{] return[call[.zip, parameter[member[.srcPath], member[.zipPath], literal[false]]]] end[}] END[}]
Keyword[public] Keyword[static] identifier[File] identifier[zip] operator[SEP] identifier[String] identifier[srcPath] , identifier[String] identifier[zipPath] operator[SEP] Keyword[throws] identifier[UtilException] { Keyword[return] identifier[zip] operator[SEP] identifier[srcPath] , identifier[zipPath] , lit...
public void setAmbientLight(int i, Color color, boolean enableColor, Vector3D v) { float ambient[] = { (float)color.getRed(), (float)color.getGreen(), (float)color.getBlue(), (float)color.getAlpha() }; float position[] = { (float)v.getX(), (floa...
class class_name[name] begin[{] method[setAmbientLight, return_type[void], modifier[public], parameter[i, color, enableColor, v]] begin[{] local_variable[type[float], ambient] local_variable[type[float], position] call[gl.glEnable, parameter[member[GL2.GL_LIGHTING]]] ...
Keyword[public] Keyword[void] identifier[setAmbientLight] operator[SEP] Keyword[int] identifier[i] , identifier[Color] identifier[color] , Keyword[boolean] identifier[enableColor] , identifier[Vector3D] identifier[v] operator[SEP] { Keyword[float] identifier[ambient] operator[SEP] operator[SEP] operator[=] {...
@Override public Long lInsert(byte[] key, Position where, byte[] pivot, byte[] value) { try { if (isPipelined()) { pipeline(new JedisResult(pipeline.linsert(key, JedisConverters.toListPosition(where), pivot, value))); return null; } return...
class class_name[name] begin[{] method[lInsert, return_type[type[Long]], modifier[public], parameter[key, where, pivot, value]] begin[{] TryStatement(block=[IfStatement(condition=MethodInvocation(arguments=[], member=isPipelined, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type...
annotation[@] identifier[Override] Keyword[public] identifier[Long] identifier[lInsert] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[key] , identifier[Position] identifier[where] , Keyword[byte] operator[SEP] operator[SEP] identifier[pivot] , Keyword[byte] operator[SEP] operator[SEP] identifier...
public double getPercentileAtOrBelowValue(final long value) { if (getTotalCount() == 0) { return 100.0; } final int targetIndex = Math.min(countsArrayIndex(value), (countsArrayLength - 1)); long totalToCurrentIndex = 0; for (int i = 0; i <= targetIndex; i++) { ...
class class_name[name] begin[{] method[getPercentileAtOrBelowValue, return_type[type[double]], modifier[public], parameter[value]] begin[{] if[binary_operation[call[.getTotalCount, parameter[]], ==, literal[0]]] begin[{] return[literal[100.0]] else begin[{] None end[...
Keyword[public] Keyword[double] identifier[getPercentileAtOrBelowValue] operator[SEP] Keyword[final] Keyword[long] identifier[value] operator[SEP] { Keyword[if] operator[SEP] identifier[getTotalCount] operator[SEP] operator[SEP] operator[==] Other[0] operator[SEP] { Keyword[return] literal[Float] oper...
public BufferedImage acquireImage(ScanListener listener) throws IOException, SaneException { Preconditions.checkState(isOpen(), "device is not open"); if (listener == null) { listener = new ScanListenerAdapter(); } return session.acquireImage(this, listener); }
class class_name[name] begin[{] method[acquireImage, return_type[type[BufferedImage]], modifier[public], parameter[listener]] begin[{] call[Preconditions.checkState, parameter[call[.isOpen, parameter[]], literal["device is not open"]]] if[binary_operation[member[.listener], ==, ...
Keyword[public] identifier[BufferedImage] identifier[acquireImage] operator[SEP] identifier[ScanListener] identifier[listener] operator[SEP] Keyword[throws] identifier[IOException] , identifier[SaneException] { identifier[Preconditions] operator[SEP] identifier[checkState] operator[SEP] identifier[isOpen] opera...
public void add(FutureReadResultEntry entry) { synchronized (this.reads) { Exceptions.checkNotClosed(this.closed, this); this.reads.add(entry); } }
class class_name[name] begin[{] method[add, return_type[void], modifier[public], parameter[entry]] begin[{] SYNCHRONIZED[THIS[member[None.reads]]] BEGIN[{] call[Exceptions.checkNotClosed, parameter[THIS[member[None.closed]], THIS[]]] THIS[member[N...
Keyword[public] Keyword[void] identifier[add] operator[SEP] identifier[FutureReadResultEntry] identifier[entry] operator[SEP] { Keyword[synchronized] operator[SEP] Keyword[this] operator[SEP] identifier[reads] operator[SEP] { identifier[Exceptions] operator[SEP] identifier[checkNotClosed] operator[SEP...
@Override protected boolean mutatesTo(Object o1, Object o2) { if (this.propertyNames.length > 0) { if (BeansUtils.declaredEquals(o1.getClass())) { return o1.equals(o2); } } return super.mutatesTo(o1, o2); }
class class_name[name] begin[{] method[mutatesTo, return_type[type[boolean]], modifier[protected], parameter[o1, o2]] begin[{] if[binary_operation[THIS[member[None.propertyNames]member[None.length]], >, literal[0]]] begin[{] if[call[BeansUtils.declaredEquals, parameter[c...
annotation[@] identifier[Override] Keyword[protected] Keyword[boolean] identifier[mutatesTo] operator[SEP] identifier[Object] identifier[o1] , identifier[Object] identifier[o2] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[propertyNames] operator[SEP] identifier[length] operat...
public static int poolid(int agentid) { int poolid = agentid / poolsize; if (poolid + 1 > npools) { poolid = npools - 1; } return poolid; }
class class_name[name] begin[{] method[poolid, return_type[type[int]], modifier[public static], parameter[agentid]] begin[{] local_variable[type[int], poolid] if[binary_operation[binary_operation[member[.poolid], +, literal[1]], >, member[.npools]]] begin[{] assi...
Keyword[public] Keyword[static] Keyword[int] identifier[poolid] operator[SEP] Keyword[int] identifier[agentid] operator[SEP] { Keyword[int] identifier[poolid] operator[=] identifier[agentid] operator[/] identifier[poolsize] operator[SEP] Keyword[if] operator[SEP] identifier[poolid] operator[+] Other[1] operator[...
void initialize(AbstractCompiler compiler) throws Exception { checkState( !Strings.isNullOrEmpty(templateJs), "The template JS must be loaded before the scanner is used. " + "Make sure that the template file is not empty."); Node scriptRoot = new JsAst(SourceFile.fromCode( "t...
class class_name[name] begin[{] method[initialize, return_type[void], modifier[default], parameter[compiler]] begin[{] call[.checkState, parameter[call[Strings.isNullOrEmpty, parameter[member[.templateJs]]], binary_operation[literal["The template JS must be loaded before the scanner is used. "]...
Keyword[void] identifier[initialize] operator[SEP] identifier[AbstractCompiler] identifier[compiler] operator[SEP] Keyword[throws] identifier[Exception] { identifier[checkState] operator[SEP] operator[!] identifier[Strings] operator[SEP] identifier[isNullOrEmpty] operator[SEP] identifier[templateJs] operator[SEP...
private static String generateAliasRoot(String description) { String result = truncate(unqualifyEntityName(description), ALIAS_TRUNCATE_LENGTH) // Important to use Locale.ENGLISH. See HHH-8579. #toLowerCase() uses the default Locale. Certain DBs // do not like non-ascii characters in aliases, etc...
class class_name[name] begin[{] method[generateAliasRoot, return_type[type[String]], modifier[private static], parameter[description]] begin[{] local_variable[type[String], result] assign[member[.result], call[.cleanAlias, parameter[member[.result]]]] if[call[Character.i...
Keyword[private] Keyword[static] identifier[String] identifier[generateAliasRoot] operator[SEP] identifier[String] identifier[description] operator[SEP] { identifier[String] identifier[result] operator[=] identifier[truncate] operator[SEP] identifier[unqualifyEntityName] operator[SEP] identifier[description] ope...
public Observable<Page<CloudJobSchedule>> listAsync(final JobScheduleListOptions jobScheduleListOptions) { return listWithServiceResponseAsync(jobScheduleListOptions) .map(new Func1<ServiceResponseWithHeaders<Page<CloudJobSchedule>, JobScheduleListHeaders>, Page<CloudJobSchedule>>() { ...
class class_name[name] begin[{] method[listAsync, return_type[type[Observable]], modifier[public], parameter[jobScheduleListOptions]] begin[{] return[call[.listWithServiceResponseAsync, parameter[member[.jobScheduleListOptions]]]] end[}] END[}]
Keyword[public] identifier[Observable] operator[<] identifier[Page] operator[<] identifier[CloudJobSchedule] operator[>] operator[>] identifier[listAsync] operator[SEP] Keyword[final] identifier[JobScheduleListOptions] identifier[jobScheduleListOptions] operator[SEP] { Keyword[return] identifier[listWithServiceR...
public PullResult pullFromRepository(Git git, String remote, String remoteBranch) { try { return git.pull() .setRemote(remote) .setRemoteBranchName(remoteBranch) .call(); } catch (GitAPIException e) { throw new IllegalStateException...
class class_name[name] begin[{] method[pullFromRepository, return_type[type[PullResult]], modifier[public], parameter[git, remote, remoteBranch]] begin[{] TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[], member=pull, postfix_operators=[], prefix_operators=[], qualifier=git,...
Keyword[public] identifier[PullResult] identifier[pullFromRepository] operator[SEP] identifier[Git] identifier[git] , identifier[String] identifier[remote] , identifier[String] identifier[remoteBranch] operator[SEP] { Keyword[try] { Keyword[return] identifier[git] operator[SEP] identifier[pull] oper...
protected List<HalResource<?>> resolveCachedLinks(String[] linkedIds, Cache cache, List<String> notCachedLinkedIds) { ArrayList<HalResource<?>> resolvedResources = new ArrayList<HalResource<?>>(); for (String linkedId : linkedIds) { HalResource<?> resource = (HalResource<?>) cache.get(linkedId); if...
class class_name[name] begin[{] method[resolveCachedLinks, return_type[type[List]], modifier[protected], parameter[linkedIds, cache, notCachedLinkedIds]] begin[{] local_variable[type[ArrayList], resolvedResources] ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration...
Keyword[protected] identifier[List] operator[<] identifier[HalResource] operator[<] operator[?] operator[>] operator[>] identifier[resolveCachedLinks] operator[SEP] identifier[String] operator[SEP] operator[SEP] identifier[linkedIds] , identifier[Cache] identifier[cache] , identifier[List] operator[<] identifier[Stri...
@SuppressWarnings("unchecked") private KeyEntitySchemaParser<?, ?> getSchemaParser( String schemaParserClassName) { if (schemaParsers.contains(schemaParserClassName)) { return schemaParsers.get(schemaParserClassName); } else { try { Class<KeyEntitySchemaParser<?, ?>> schemaParserClas...
class class_name[name] begin[{] method[getSchemaParser, return_type[type[KeyEntitySchemaParser]], modifier[private], parameter[schemaParserClassName]] begin[{] if[call[schemaParsers.contains, parameter[member[.schemaParserClassName]]]] begin[{] return[call[schemaParsers.get, paramet...
annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[private] identifier[KeyEntitySchemaParser] operator[<] operator[?] , operator[?] operator[>] identifier[getSchemaParser] operator[SEP] identifier[String] identifier[schemaParserClassName] operator[SEP] { Keyword[if] o...
public static void register(IRegisterable<?> registerable) { ResourceLocation name = registerable.getName(); if (name == null) throw new IllegalArgumentException("No name specified for registration for " + registerable.getClass().getName()); if (!(registerable instanceof Block || registerable instanceof Item)...
class class_name[name] begin[{] method[register, return_type[void], modifier[public static], parameter[registerable]] begin[{] local_variable[type[ResourceLocation], name] if[binary_operation[member[.name], ==, literal[null]]] begin[{] ThrowStatement(expression=ClassCreator(arguments=[B...
Keyword[public] Keyword[static] Keyword[void] identifier[register] operator[SEP] identifier[IRegisterable] operator[<] operator[?] operator[>] identifier[registerable] operator[SEP] { identifier[ResourceLocation] identifier[name] operator[=] identifier[registerable] operator[SEP] identifier[getName] operator[SEP...
public static int getAtomCount(IMolecularFormula formula) { int count = 0; for (IIsotope isotope : formula.isotopes()) { count += formula.getIsotopeCount(isotope); } return count; }
class class_name[name] begin[{] method[getAtomCount, return_type[type[int]], modifier[public static], parameter[formula]] begin[{] local_variable[type[int], count] ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=Assignment(expressionl=MemberReference(memb...
Keyword[public] Keyword[static] Keyword[int] identifier[getAtomCount] operator[SEP] identifier[IMolecularFormula] identifier[formula] operator[SEP] { Keyword[int] identifier[count] operator[=] Other[0] operator[SEP] Keyword[for] operator[SEP] identifier[IIsotope] identifier[isotope] operator[:] identifier[formu...
public static void setClassConf(Class<? extends Message> protoClass, Configuration conf) { Protobufs.setClassConf(conf, RCFileProtobufInputFormat.class, protoClass); }
class class_name[name] begin[{] method[setClassConf, return_type[void], modifier[public static], parameter[protoClass, conf]] begin[{] call[Protobufs.setClassConf, parameter[member[.conf], ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type=ReferenceType(arg...
Keyword[public] Keyword[static] Keyword[void] identifier[setClassConf] operator[SEP] identifier[Class] operator[<] operator[?] Keyword[extends] identifier[Message] operator[>] identifier[protoClass] , identifier[Configuration] identifier[conf] operator[SEP] { identifier[Protobufs] operator[SEP] identifier[setCl...
@GwtIncompatible("incompatible method") public static boolean isAssignable(final Class<?>[] classArray, final Class<?>... toClassArray) { return isAssignable(classArray, toClassArray, SystemUtils.isJavaVersionAtLeast(JavaVersion.JAVA_1_5)); }
class class_name[name] begin[{] method[isAssignable, return_type[type[boolean]], modifier[public static], parameter[classArray, toClassArray]] begin[{] return[call[.isAssignable, parameter[member[.classArray], member[.toClassArray], call[SystemUtils.isJavaVersionAtLeast, parameter[member[JavaVersion.JA...
annotation[@] identifier[GwtIncompatible] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[static] Keyword[boolean] identifier[isAssignable] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] operator[>] operator[SEP] operator[SEP] identifier[classArray] , Keyword[final] identifi...
@Override public T addPackage(Package pack) throws IllegalArgumentException { Validate.notNull(pack, "Pack must be specified"); return addPackage(pack.getName()); }
class class_name[name] begin[{] method[addPackage, return_type[type[T]], modifier[public], parameter[pack]] begin[{] call[Validate.notNull, parameter[member[.pack], literal["Pack must be specified"]]] return[call[.addPackage, parameter[call[pack.getName, parameter[]]]]] end[}] END[}...
annotation[@] identifier[Override] Keyword[public] identifier[T] identifier[addPackage] operator[SEP] identifier[Package] identifier[pack] operator[SEP] Keyword[throws] identifier[IllegalArgumentException] { identifier[Validate] operator[SEP] identifier[notNull] operator[SEP] identifier[pack] , literal[String] ...
@Override public Object convert(String value) { Object converted = null; if (value != null) { //if the value is null then we always return null try { if (this.ctor != null) { converted = this.ctor.newInstance(value); } else if (this.val...
class class_name[name] begin[{] method[convert, return_type[type[Object]], modifier[public], parameter[value]] begin[{] local_variable[type[Object], converted] if[binary_operation[member[.value], !=, literal[null]]] begin[{] TryStatement(block=[IfStatement(condition=BinaryOp...
annotation[@] identifier[Override] Keyword[public] identifier[Object] identifier[convert] operator[SEP] identifier[String] identifier[value] operator[SEP] { identifier[Object] identifier[converted] operator[=] Other[null] operator[SEP] Keyword[if] operator[SEP] identifier[value] operator[!=] Other[null] operator...
private static int parseJavaVersion() { String[] parts = JAVA_SPECIFICATION_VERSION.split("\\."); int nbParts = parts.length; int majorIndex = nbParts > 1 ? 1 : 0; return Integer.parseInt(parts[majorIndex]); }
class class_name[name] begin[{] method[parseJavaVersion, return_type[type[int]], modifier[private static], parameter[]] begin[{] local_variable[type[String], parts] local_variable[type[int], nbParts] local_variable[type[int], majorIndex] return[call[Integer.parseInt, parameter[m...
Keyword[private] Keyword[static] Keyword[int] identifier[parseJavaVersion] operator[SEP] operator[SEP] { identifier[String] operator[SEP] operator[SEP] identifier[parts] operator[=] identifier[JAVA_SPECIFICATION_VERSION] operator[SEP] identifier[split] operator[SEP] literal[String] operator[SEP] operator[SEP] Ke...
@Override public void createCacheFileAsync(final String fileNamePrefix, final InputStream is, final CreateCompletionCallback callback) { _aggregator.getExecutors().getFileCreateExecutor().submit(new Runnable() { public void run() { File file = null; try { file = File.createTempFile(fileNa...
class class_name[name] begin[{] method[createCacheFileAsync, return_type[void], modifier[public], parameter[fileNamePrefix, is, callback]] begin[{] call[_aggregator.getExecutors, parameter[]] end[}] END[}]
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[createCacheFileAsync] operator[SEP] Keyword[final] identifier[String] identifier[fileNamePrefix] , Keyword[final] identifier[InputStream] identifier[is] , Keyword[final] identifier[CreateCompletionCallback] identifier[callback] operator[SEP] ...
public void init(ModeledAuthenticatedUser currentUser, ModeledPermissions<? extends EntityModel> entity, Set<String> effectiveGroups) { super.init(currentUser); this.entity = entity; this.effectiveGroups = effectiveGroups; }
class class_name[name] begin[{] method[init, return_type[void], modifier[public], parameter[currentUser, entity, effectiveGroups]] begin[{] SuperMethodInvocation(arguments=[MemberReference(member=currentUser, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], member=init, po...
Keyword[public] Keyword[void] identifier[init] operator[SEP] identifier[ModeledAuthenticatedUser] identifier[currentUser] , identifier[ModeledPermissions] operator[<] operator[?] Keyword[extends] identifier[EntityModel] operator[>] identifier[entity] , identifier[Set] operator[<] identifier[String] operator[>] identi...
private void checkInterface(Node n, FunctionType functionType) { // Interface must extend only interfaces for (ObjectType extInterface : functionType.getExtendedInterfaces()) { if (extInterface.getConstructor() != null && !extInterface.getConstructor().isInterface()) { compiler.report( ...
class class_name[name] begin[{] method[checkInterface, return_type[void], modifier[private], parameter[n, functionType]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=BinaryOperation(operandl=MethodInvocation(arguments=[], member=getCon...
Keyword[private] Keyword[void] identifier[checkInterface] operator[SEP] identifier[Node] identifier[n] , identifier[FunctionType] identifier[functionType] operator[SEP] { Keyword[for] operator[SEP] identifier[ObjectType] identifier[extInterface] operator[:] identifier[functionType] operator[SEP] identifier[get...
private void addAssignments(MpxjTreeNode parentNode, ProjectFile file) { for (ResourceAssignment assignment : file.getResourceAssignments()) { final ResourceAssignment a = assignment; MpxjTreeNode childNode = new MpxjTreeNode(a) { @Override public String toString() ...
class class_name[name] begin[{] method[addAssignments, return_type[void], modifier[private], parameter[parentNode, file]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MemberReference...
Keyword[private] Keyword[void] identifier[addAssignments] operator[SEP] identifier[MpxjTreeNode] identifier[parentNode] , identifier[ProjectFile] identifier[file] operator[SEP] { Keyword[for] operator[SEP] identifier[ResourceAssignment] identifier[assignment] operator[:] identifier[file] operator[SEP] identifi...
static final void put6Bit(final WritableMemory wmem, final int offsetBytes, final int slotNo, final int newValue) { final int startBit = slotNo * 6; final int shift = startBit & 0X7; final int byteIdx = (startBit >>> 3) + offsetBytes; final int valShifted = (newValue & 0X3F) << shift; final in...
class class_name[name] begin[{] method[put6Bit, return_type[void], modifier[final static], parameter[wmem, offsetBytes, slotNo, newValue]] begin[{] local_variable[type[int], startBit] local_variable[type[int], shift] local_variable[type[int], byteIdx] local_variable[type[int], v...
Keyword[static] Keyword[final] Keyword[void] identifier[put6Bit] operator[SEP] Keyword[final] identifier[WritableMemory] identifier[wmem] , Keyword[final] Keyword[int] identifier[offsetBytes] , Keyword[final] Keyword[int] identifier[slotNo] , Keyword[final] Keyword[int] identifier[newValue] operator[SEP] { Ke...
public static StringBuilder getContextUrlString(String baseUrl, String context) throws MalformedURLException { StringBuilder urlStr = new StringBuilder(baseUrl); ensureEndsWithSlash(urlStr); if (context != null && context.length() > 0) { if (context.startsWith("/")) { ...
class class_name[name] begin[{] method[getContextUrlString, return_type[type[StringBuilder]], modifier[public static], parameter[baseUrl, context]] begin[{] local_variable[type[StringBuilder], urlStr] call[.ensureEndsWithSlash, parameter[member[.urlStr]]] if[binary_opera...
Keyword[public] Keyword[static] identifier[StringBuilder] identifier[getContextUrlString] operator[SEP] identifier[String] identifier[baseUrl] , identifier[String] identifier[context] operator[SEP] Keyword[throws] identifier[MalformedURLException] { identifier[StringBuilder] identifier[urlStr] operator[=] Keywo...
public DataObject object(File[] files, int start, int count) { return STRUCT.fromMapsAndCollections(map(files, start, count)); }
class class_name[name] begin[{] method[object, return_type[type[DataObject]], modifier[public], parameter[files, start, count]] begin[{] return[call[STRUCT.fromMapsAndCollections, parameter[call[.map, parameter[member[.files], member[.start], member[.count]]]]]] end[}] END[}]
Keyword[public] identifier[DataObject] identifier[object] operator[SEP] identifier[File] operator[SEP] operator[SEP] identifier[files] , Keyword[int] identifier[start] , Keyword[int] identifier[count] operator[SEP] { Keyword[return] identifier[STRUCT] operator[SEP] identifier[fromMapsAndCollections] operator[S...
@Override protected ModelAndView handleRequestInternal(final HttpServletRequest request, final HttpServletResponse response) throws Exception { for (val delegate : this.delegates) { if (delegate.canHandle(request, response)) { return delegate.handleRequestInternal(request, respon...
class class_name[name] begin[{] method[handleRequestInternal, return_type[type[ModelAndView]], modifier[protected], parameter[request, response]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=request, postfix_o...
annotation[@] identifier[Override] Keyword[protected] identifier[ModelAndView] identifier[handleRequestInternal] operator[SEP] Keyword[final] identifier[HttpServletRequest] identifier[request] , Keyword[final] identifier[HttpServletResponse] identifier[response] operator[SEP] Keyword[throws] identifier[Exception] { ...
public ListTopicsResult withTopics(Topic... topics) { if (this.topics == null) { setTopics(new com.amazonaws.internal.SdkInternalList<Topic>(topics.length)); } for (Topic ele : topics) { this.topics.add(ele); } return this; }
class class_name[name] begin[{] method[withTopics, return_type[type[ListTopicsResult]], modifier[public], parameter[topics]] begin[{] if[binary_operation[THIS[member[None.topics]], ==, literal[null]]] begin[{] call[.setTopics, parameter[ClassCreator(arguments=[MemberRefe...
Keyword[public] identifier[ListTopicsResult] identifier[withTopics] operator[SEP] identifier[Topic] operator[...] identifier[topics] operator[SEP] { Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[topics] operator[==] Other[null] operator[SEP] { identifier[setTopics] operator[SEP] Key...
public void becomeCloneOf(ManagedObject other) { if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled()) trace.entry(this, cclass, "becomeCloneOf", "Other=" + other); super.becomeCloneOf(other);...
class class_name[name] begin[{] method[becomeCloneOf, return_type[void], modifier[public], parameter[other]] begin[{] if[binary_operation[call[Tracing.isAnyTracingEnabled, parameter[]], &&, call[trace.isEntryEnabled, parameter[]]]] begin[{] call[trace.entry, parameter[THIS[], member...
Keyword[public] Keyword[void] identifier[becomeCloneOf] operator[SEP] identifier[ManagedObject] identifier[other] operator[SEP] { Keyword[if] operator[SEP] identifier[Tracing] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identifier[trace] operator[SEP] identifier[isEntry...
public StylesheetComposed getImportComposed(int i) throws ArrayIndexOutOfBoundsException { StylesheetRoot root = getStylesheetRoot(); // Get the stylesheet that is offset past this stylesheet. // Thus, if the index of this stylesheet is 3, an argument // to getImportComposed of 0 will ret...
class class_name[name] begin[{] method[getImportComposed, return_type[type[StylesheetComposed]], modifier[public], parameter[i]] begin[{] local_variable[type[StylesheetRoot], root] return[call[root.getGlobalImport, parameter[binary_operation[binary_operation[literal[1], +, member[.m_importNumbe...
Keyword[public] identifier[StylesheetComposed] identifier[getImportComposed] operator[SEP] Keyword[int] identifier[i] operator[SEP] Keyword[throws] identifier[ArrayIndexOutOfBoundsException] { identifier[StylesheetRoot] identifier[root] operator[=] identifier[getStylesheetRoot] operator[SEP] operator[SEP] operat...
private String getServletPath(final String relativePath) { if (relativePath == null) { LOG.error("relativePath must not be null"); } String context = getHostFreeBaseUrl(); if (!Util.empty(context)) { return context + relativePath; } return relativePath; }
class class_name[name] begin[{] method[getServletPath, return_type[type[String]], modifier[private], parameter[relativePath]] begin[{] if[binary_operation[member[.relativePath], ==, literal[null]]] begin[{] call[LOG.error, parameter[literal["relativePath must not be null...
Keyword[private] identifier[String] identifier[getServletPath] operator[SEP] Keyword[final] identifier[String] identifier[relativePath] operator[SEP] { Keyword[if] operator[SEP] identifier[relativePath] operator[==] Other[null] operator[SEP] { identifier[LOG] operator[SEP] identifier[error] operator[S...
public static int getInt(String name, int defaultVal){ if(getConfiguration().containsKey(name)){ return getConfiguration().getInt(name); } else { return defaultVal; } }
class class_name[name] begin[{] method[getInt, return_type[type[int]], modifier[public static], parameter[name, defaultVal]] begin[{] if[call[.getConfiguration, parameter[]]] begin[{] return[call[.getConfiguration, parameter[]]] else begin[{] return[member[.defau...
Keyword[public] Keyword[static] Keyword[int] identifier[getInt] operator[SEP] identifier[String] identifier[name] , Keyword[int] identifier[defaultVal] operator[SEP] { Keyword[if] operator[SEP] identifier[getConfiguration] operator[SEP] operator[SEP] operator[SEP] identifier[containsKey] operator[SEP] identifie...
@Override public SocketRuntime createRuntime(DefaultFuture future, Options options, List<FunctionWrapper> functions) { return new SerialSocketRuntime(transportInUse, options, new DefaultFuture(this), this, functions); }
class class_name[name] begin[{] method[createRuntime, return_type[type[SocketRuntime]], modifier[public], parameter[future, options, functions]] begin[{] return[ClassCreator(arguments=[MemberReference(member=transportInUse, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberRef...
annotation[@] identifier[Override] Keyword[public] identifier[SocketRuntime] identifier[createRuntime] operator[SEP] identifier[DefaultFuture] identifier[future] , identifier[Options] identifier[options] , identifier[List] operator[<] identifier[FunctionWrapper] operator[>] identifier[functions] operator[SEP] { ...
protected Set<IEntityGroup> primGetAncestorGroups(IGroupMember member, Set<IEntityGroup> rslt) throws GroupsException { for (IEntityGroup group : member.getParentGroups()) { // avoid stack overflow in case of circular group dependencies if (!rslt.contains(group)) { ...
class class_name[name] begin[{] method[primGetAncestorGroups, return_type[type[Set]], modifier[protected], parameter[member, rslt]] begin[{] ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=group, postfix_operators=[], pre...
Keyword[protected] identifier[Set] operator[<] identifier[IEntityGroup] operator[>] identifier[primGetAncestorGroups] operator[SEP] identifier[IGroupMember] identifier[member] , identifier[Set] operator[<] identifier[IEntityGroup] operator[>] identifier[rslt] operator[SEP] Keyword[throws] identifier[GroupsException] ...
@Override public java.util.concurrent.Future<BatchWriteItemResult> batchWriteItemAsync(java.util.Map<String, java.util.List<WriteRequest>> requestItems) { return batchWriteItemAsync(new BatchWriteItemRequest().withRequestItems(requestItems)); }
class class_name[name] begin[{] method[batchWriteItemAsync, return_type[type[java]], modifier[public], parameter[requestItems]] begin[{] return[call[.batchWriteItemAsync, parameter[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifie...
annotation[@] identifier[Override] Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[concurrent] operator[SEP] identifier[Future] operator[<] identifier[BatchWriteItemResult] operator[>] identifier[batchWriteItemAsync] operator[SEP] identifier[java] operator[SEP] identifier[util] ...