code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public static MomentInterval parseISO(String text)
throws ParseException {
if (text.isEmpty()) {
throw new IndexOutOfBoundsException("Empty text.");
}
// prescan for format analysis
int start = 0;
int n = Math.min(text.length(), 117);
boolean sameFormat = true;
... | class class_name[name] begin[{]
method[parseISO, return_type[type[MomentInterval]], modifier[public static], parameter[text]] begin[{]
if[call[text.isEmpty, parameter[]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qu... | Keyword[public] Keyword[static] identifier[MomentInterval] identifier[parseISO] operator[SEP] identifier[String] identifier[text] operator[SEP] Keyword[throws] identifier[ParseException] {
Keyword[if] operator[SEP] identifier[text] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] {
... |
public static KvStateClientProxy createKvStateClientProxy(
final InetAddress address,
final Iterator<Integer> ports,
final int eventLoopThreads,
final int queryThreads,
final KvStateRequestStats stats) {
Preconditions.checkNotNull(address, "address");
Preconditions.checkNotNull(stats, "stats");
P... | class class_name[name] begin[{]
method[createKvStateClientProxy, return_type[type[KvStateClientProxy]], modifier[public static], parameter[address, ports, eventLoopThreads, queryThreads, stats]] begin[{]
call[Preconditions.checkNotNull, parameter[member[.address], literal["address"]]]
... | Keyword[public] Keyword[static] identifier[KvStateClientProxy] identifier[createKvStateClientProxy] operator[SEP] Keyword[final] identifier[InetAddress] identifier[address] , Keyword[final] identifier[Iterator] operator[<] identifier[Integer] operator[>] identifier[ports] , Keyword[final] Keyword[int] identifier[even... |
public static void validateLifeCycleSignature(InterceptorMethodKind kind, String lifeCycle, Method m, boolean ejbClass, J2EEName name)
throws EJBConfigurationException
{
// Validate method signature except for the parameter types,
// which is done by this method.
validate... | class class_name[name] begin[{]
method[validateLifeCycleSignature, return_type[void], modifier[public static], parameter[kind, lifeCycle, m, ejbClass, name]] begin[{]
call[.validateLifeCycleSignatureExceptParameters, parameter[member[.kind], member[.lifeCycle], member[.m], member[.ejbClass], me... | Keyword[public] Keyword[static] Keyword[void] identifier[validateLifeCycleSignature] operator[SEP] identifier[InterceptorMethodKind] identifier[kind] , identifier[String] identifier[lifeCycle] , identifier[Method] identifier[m] , Keyword[boolean] identifier[ejbClass] , identifier[J2EEName] identifier[name] operator... |
public int appendAll(OptionalParameter[] optionalParameters) {
int length = 0;
for (OptionalParameter optionalParamameter : optionalParameters) {
length += append(optionalParamameter);
}
return length;
} | class class_name[name] begin[{]
method[appendAll, return_type[type[int]], modifier[public], parameter[optionalParameters]] begin[{]
local_variable[type[int], length]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=Assignment(expressionl=MemberReference(me... | Keyword[public] Keyword[int] identifier[appendAll] operator[SEP] identifier[OptionalParameter] operator[SEP] operator[SEP] identifier[optionalParameters] operator[SEP] {
Keyword[int] identifier[length] operator[=] Other[0] operator[SEP] Keyword[for] operator[SEP] identifier[OptionalParameter] identifier[optional... |
public void addComponent(ComponentDescription description) {
final String componentName = description.getComponentName();
final String componentClassName = description.getComponentClassName();
if (componentName == null) {
throw EeLogger.ROOT_LOGGER.nullVar("componentName", "module", ... | class class_name[name] begin[{]
method[addComponent, return_type[void], modifier[public], parameter[description]] begin[{]
local_variable[type[String], componentName]
local_variable[type[String], componentClassName]
if[binary_operation[member[.componentName], ==, literal[null]]]... | Keyword[public] Keyword[void] identifier[addComponent] operator[SEP] identifier[ComponentDescription] identifier[description] operator[SEP] {
Keyword[final] identifier[String] identifier[componentName] operator[=] identifier[description] operator[SEP] identifier[getComponentName] operator[SEP] operator[SEP] oper... |
protected int getNextIndex(final int currentIndex) {
if (!isPaused()) {
return currentIndex + 1;
}
int ret = currentIndex;
while (isPaused()) {
sendStepPausing(ret + 1);
try {
Thread.sleep(getPauseSpan());
... | class class_name[name] begin[{]
method[getNextIndex, return_type[type[int]], modifier[protected], parameter[currentIndex]] begin[{]
if[call[.isPaused, parameter[]]] begin[{]
return[binary_operation[member[.currentIndex], +, literal[1]]]
else begin[{]
None
end[}]
... | Keyword[protected] Keyword[int] identifier[getNextIndex] operator[SEP] Keyword[final] Keyword[int] identifier[currentIndex] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[isPaused] operator[SEP] operator[SEP] operator[SEP] {
Keyword[return] identifier[currentIndex] operator[+] Other[... |
public void setStyleName(String v) {
if (Style_Type.featOkTst && ((Style_Type)jcasType).casFeat_styleName == null)
jcasType.jcas.throwFeatMissing("styleName", "de.julielab.jules.types.Style");
jcasType.ll_cas.ll_setStringValue(addr, ((Style_Type)jcasType).casFeatCode_styleName, v);} | class class_name[name] begin[{]
method[setStyleName, return_type[void], modifier[public], parameter[v]] begin[{]
if[binary_operation[member[Style_Type.featOkTst], &&, binary_operation[Cast(expression=MemberReference(member=jcasType, postfix_operators=[], prefix_operators=[], qualifier=, selecto... | Keyword[public] Keyword[void] identifier[setStyleName] operator[SEP] identifier[String] identifier[v] operator[SEP] {
Keyword[if] operator[SEP] identifier[Style_Type] operator[SEP] identifier[featOkTst] operator[&&] operator[SEP] operator[SEP] identifier[Style_Type] operator[SEP] identifier[jcasType] operator[SE... |
public final DoubleProperty rowHeightProperty() {
if (rowHeight == null) {
rowHeight = new StyleableDoubleProperty(20) {
@Override
public CssMetaData<AllDayView, Number> getCssMetaData() {
return StyleableProperties.ROW_HEIGHT;
}
... | class class_name[name] begin[{]
method[rowHeightProperty, return_type[type[DoubleProperty]], modifier[final public], parameter[]] begin[{]
if[binary_operation[member[.rowHeight], ==, literal[null]]] begin[{]
assign[member[.rowHeight], ClassCreator(arguments=[Literal(post... | Keyword[public] Keyword[final] identifier[DoubleProperty] identifier[rowHeightProperty] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[rowHeight] operator[==] Other[null] operator[SEP] {
identifier[rowHeight] operator[=] Keyword[new] identifier[StyleableDoubleProperty] operator[SEP... |
protected boolean isButtonEnabledForSelectedMessages(List<HttpMessage> httpMessages) {
for (HttpMessage httpMessage : httpMessages) {
if (httpMessage != null && !isButtonEnabledForSelectedHttpMessage(httpMessage)) {
return false;
}
}
return true;
} | class class_name[name] begin[{]
method[isButtonEnabledForSelectedMessages, return_type[type[boolean]], modifier[protected], parameter[httpMessages]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=BinaryOperation(operandl=MemberReference(... | Keyword[protected] Keyword[boolean] identifier[isButtonEnabledForSelectedMessages] operator[SEP] identifier[List] operator[<] identifier[HttpMessage] operator[>] identifier[httpMessages] operator[SEP] {
Keyword[for] operator[SEP] identifier[HttpMessage] identifier[httpMessage] operator[:] identifier[httpMessage... |
private void reportException(int s) {
Throwable ex = ((s == CANCELLED) ? new CancellationException() :
(s == EXCEPTIONAL) ? getThrowableException() :
null);
if (ex != null)
U.throwException(ex);
} | class class_name[name] begin[{]
method[reportException, return_type[void], modifier[private], parameter[s]] begin[{]
local_variable[type[Throwable], ex]
if[binary_operation[member[.ex], !=, literal[null]]] begin[{]
call[U.throwException, parameter[member[.ex]]]
else ... | Keyword[private] Keyword[void] identifier[reportException] operator[SEP] Keyword[int] identifier[s] operator[SEP] {
identifier[Throwable] identifier[ex] operator[=] operator[SEP] operator[SEP] identifier[s] operator[==] identifier[CANCELLED] operator[SEP] operator[?] Keyword[new] identifier[CancellationException... |
public double scorePath(DependencyPath path) {
double score = 0;
for (DependencyRelation wordRelation : path) {
if (wordRelation.relation().equals("SBJ"))
score += 5;
else if (wordRelation.relation().equals("OBJ"))
score += 4;
else if (... | class class_name[name] begin[{]
method[scorePath, return_type[type[double]], modifier[public], parameter[path]] begin[{]
local_variable[type[double], score]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[], member=relation, postfix_ope... | Keyword[public] Keyword[double] identifier[scorePath] operator[SEP] identifier[DependencyPath] identifier[path] operator[SEP] {
Keyword[double] identifier[score] operator[=] Other[0] operator[SEP] Keyword[for] operator[SEP] identifier[DependencyRelation] identifier[wordRelation] operator[:] identifier[path] ope... |
public PackageElement getAbbreviatedPackageElement(PackageElement pkg) {
String parsedPackageName = utils.parsePackageName(pkg);
ModuleElement encl = (ModuleElement) pkg.getEnclosingElement();
PackageElement abbrevPkg = encl == null
? utils.elementUtils.getPackageElement(parsedPa... | class class_name[name] begin[{]
method[getAbbreviatedPackageElement, return_type[type[PackageElement]], modifier[public], parameter[pkg]] begin[{]
local_variable[type[String], parsedPackageName]
local_variable[type[ModuleElement], encl]
local_variable[type[PackageElement], abbrevPkg]
... | Keyword[public] identifier[PackageElement] identifier[getAbbreviatedPackageElement] operator[SEP] identifier[PackageElement] identifier[pkg] operator[SEP] {
identifier[String] identifier[parsedPackageName] operator[=] identifier[utils] operator[SEP] identifier[parsePackageName] operator[SEP] identifier[pkg] oper... |
public static int[] getLoopColsRowsForSubregion( GridCoverage2D gridCoverage, Envelope2D subregion ) throws Exception {
GridGeometry2D gridGeometry = gridCoverage.getGridGeometry();
GridEnvelope2D subRegionGrid = gridGeometry.worldToGrid(subregion);
int minCol = subRegionGrid.x;
int maxC... | class class_name[name] begin[{]
method[getLoopColsRowsForSubregion, return_type[type[int]], modifier[public static], parameter[gridCoverage, subregion]] begin[{]
local_variable[type[GridGeometry2D], gridGeometry]
local_variable[type[GridEnvelope2D], subRegionGrid]
local_variable[type[in... | Keyword[public] Keyword[static] Keyword[int] operator[SEP] operator[SEP] identifier[getLoopColsRowsForSubregion] operator[SEP] identifier[GridCoverage2D] identifier[gridCoverage] , identifier[Envelope2D] identifier[subregion] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[GridGeometry2D] ident... |
public static String getActualTableName(final OutputWriter outputWriter) {
assert outputWriter instanceof DatastoreOutputWriter;
final DatastoreOutputWriter dow = (DatastoreOutputWriter) outputWriter;
return dow.getTableName();
} | class class_name[name] begin[{]
method[getActualTableName, return_type[type[String]], modifier[public static], parameter[outputWriter]] begin[{]
AssertStatement(condition=BinaryOperation(operandl=MemberReference(member=outputWriter, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), ... | Keyword[public] Keyword[static] identifier[String] identifier[getActualTableName] operator[SEP] Keyword[final] identifier[OutputWriter] identifier[outputWriter] operator[SEP] {
Keyword[assert] identifier[outputWriter] Keyword[instanceof] identifier[DatastoreOutputWriter] operator[SEP] Keyword[final] identifier[D... |
protected Formatter<VersionIdentifier> parseSubFormatter(CharSequenceScanner scanner, String formatPattern, StringBuilder infixBuffer,
FormatPatternStatus status) {
char c = scanner.next();
if (c == 'V') {
char segment = scanner.forceNext();
if (segment == '\0') {
throw new IllegalSta... | class class_name[name] begin[{]
method[parseSubFormatter, return_type[type[Formatter]], modifier[protected], parameter[scanner, formatPattern, infixBuffer, status]] begin[{]
local_variable[type[char], c]
if[binary_operation[member[.c], ==, literal['V']]] begin[{]
local_varia... | Keyword[protected] identifier[Formatter] operator[<] identifier[VersionIdentifier] operator[>] identifier[parseSubFormatter] operator[SEP] identifier[CharSequenceScanner] identifier[scanner] , identifier[String] identifier[formatPattern] , identifier[StringBuilder] identifier[infixBuffer] , identifier[FormatPatternS... |
public double precision(int outputNum) {
assertIndex(outputNum);
//double precision = tp / (double) (tp + fp);
return countTruePositive[outputNum] / (double) (countTruePositive[outputNum] + countFalsePositive[outputNum]);
} | class class_name[name] begin[{]
method[precision, return_type[type[double]], modifier[public], parameter[outputNum]] begin[{]
call[.assertIndex, parameter[member[.outputNum]]]
return[binary_operation[member[.countTruePositive], /, Cast(expression=BinaryOperation(operandl=MemberReference... | Keyword[public] Keyword[double] identifier[precision] operator[SEP] Keyword[int] identifier[outputNum] operator[SEP] {
identifier[assertIndex] operator[SEP] identifier[outputNum] operator[SEP] operator[SEP] Keyword[return] identifier[countTruePositive] operator[SEP] identifier[outputNum] operator[SEP] operator[/... |
void buildStatus(Runnable closure) {
GhprbBuildStatusContext context = new GhprbBuildStatusContext();
ContextExtensionPoint.executeInContext(closure, context);
extensions.add(new GhprbBuildStatus(context.getCompletedStatus()));
} | class class_name[name] begin[{]
method[buildStatus, return_type[void], modifier[default], parameter[closure]] begin[{]
local_variable[type[GhprbBuildStatusContext], context]
call[ContextExtensionPoint.executeInContext, parameter[member[.closure], member[.context]]]
call[... | Keyword[void] identifier[buildStatus] operator[SEP] identifier[Runnable] identifier[closure] operator[SEP] {
identifier[GhprbBuildStatusContext] identifier[context] operator[=] Keyword[new] identifier[GhprbBuildStatusContext] operator[SEP] operator[SEP] operator[SEP] identifier[ContextExtensionPoint] operator[SE... |
public void addTriple(final String subject, final String predicate, final String value,
final String datatype, final String language) {
addQuad(subject, predicate, value, datatype, language, "@default");
} | class class_name[name] begin[{]
method[addTriple, return_type[void], modifier[public], parameter[subject, predicate, value, datatype, language]] begin[{]
call[.addQuad, parameter[member[.subject], member[.predicate], member[.value], member[.datatype], member[.language], literal["@default"]]]
... | Keyword[public] Keyword[void] identifier[addTriple] operator[SEP] Keyword[final] identifier[String] identifier[subject] , Keyword[final] identifier[String] identifier[predicate] , Keyword[final] identifier[String] identifier[value] , Keyword[final] identifier[String] identifier[datatype] , Keyword[final] identifier... |
private static GoogleCredentials getCredentialsWithScopes(final List<String> scopes)
throws IOException {
GoogleCredentials credentials = null;
// first check whether the environment variable is set
final String googleCredentialsPath = System.getenv("HELIOS_GOOGLE_CREDENTIALS");
if (googleCredent... | class class_name[name] begin[{]
method[getCredentialsWithScopes, return_type[type[GoogleCredentials]], modifier[private static], parameter[scopes]] begin[{]
local_variable[type[GoogleCredentials], credentials]
local_variable[type[String], googleCredentialsPath]
if[binary_operati... | Keyword[private] Keyword[static] identifier[GoogleCredentials] identifier[getCredentialsWithScopes] operator[SEP] Keyword[final] identifier[List] operator[<] identifier[String] operator[>] identifier[scopes] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[GoogleCredentials] identifier[credenti... |
public SDVariable sizeAt(String name, SDVariable in, int dimension) {
SDVariable ret = f().sizeAt(in, dimension);
return updateVariableNameAndReference(ret, name);
} | class class_name[name] begin[{]
method[sizeAt, return_type[type[SDVariable]], modifier[public], parameter[name, in, dimension]] begin[{]
local_variable[type[SDVariable], ret]
return[call[.updateVariableNameAndReference, parameter[member[.ret], member[.name]]]]
end[}]
END[}] | Keyword[public] identifier[SDVariable] identifier[sizeAt] operator[SEP] identifier[String] identifier[name] , identifier[SDVariable] identifier[in] , Keyword[int] identifier[dimension] operator[SEP] {
identifier[SDVariable] identifier[ret] operator[=] identifier[f] operator[SEP] operator[SEP] operator[SEP] ide... |
public static TableCellButtonRenderer newTableCellButtonRenderer(String text)
{
return new TableCellButtonRenderer(null, null)
{
private static final long serialVersionUID = 1L;
@Override
protected String onSetText(final Object value)
{
String currentText = text;
return currentText;
}
};
... | class class_name[name] begin[{]
method[newTableCellButtonRenderer, return_type[type[TableCellButtonRenderer]], modifier[public static], parameter[text]] begin[{]
return[ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value=null), Literal(postfix_... | Keyword[public] Keyword[static] identifier[TableCellButtonRenderer] identifier[newTableCellButtonRenderer] operator[SEP] identifier[String] identifier[text] operator[SEP] {
Keyword[return] Keyword[new] identifier[TableCellButtonRenderer] operator[SEP] Other[null] , Other[null] operator[SEP] {
Keyword... |
public SipTransaction sendRequestWithTransaction(Request request, boolean viaProxy,
Dialog dialog) {
return sendRequestWithTransaction(request, viaProxy, dialog, null);
} | class class_name[name] begin[{]
method[sendRequestWithTransaction, return_type[type[SipTransaction]], modifier[public], parameter[request, viaProxy, dialog]] begin[{]
return[call[.sendRequestWithTransaction, parameter[member[.request], member[.viaProxy], member[.dialog], literal[null]]]]
end[}]
END... | Keyword[public] identifier[SipTransaction] identifier[sendRequestWithTransaction] operator[SEP] identifier[Request] identifier[request] , Keyword[boolean] identifier[viaProxy] , identifier[Dialog] identifier[dialog] operator[SEP] {
Keyword[return] identifier[sendRequestWithTransaction] operator[SEP] identifier... |
public static String getValueForPath(CmsEntity entity, String path) {
String result = null;
if (path.startsWith("/")) {
path = path.substring(1);
}
String attributeName;
if (path.contains("/")) {
attributeName = path.substring(0, path.indexOf("/")... | class class_name[name] begin[{]
method[getValueForPath, return_type[type[String]], modifier[public static], parameter[entity, path]] begin[{]
local_variable[type[String], result]
if[call[path.startsWith, parameter[literal["/"]]]] begin[{]
assign[member[.path], ca... | Keyword[public] Keyword[static] identifier[String] identifier[getValueForPath] operator[SEP] identifier[CmsEntity] identifier[entity] , identifier[String] identifier[path] operator[SEP] {
identifier[String] identifier[result] operator[=] Other[null] operator[SEP] Keyword[if] operator[SEP] identifier[path] opera... |
public List<E> next() {
if (numLeft.equals(total)) {
numLeft = numLeft.subtract(BigInteger.ONE);
return items;
}
int temp;
// Find largest index j with a[j] < a[j+1]
int j = a.length - 2;
while (a[j] > a[j + 1]) {
j--;
... | class class_name[name] begin[{]
method[next, return_type[type[List]], modifier[public], parameter[]] begin[{]
if[call[numLeft.equals, parameter[member[.total]]]] begin[{]
assign[member[.numLeft], call[numLeft.subtract, parameter[member[BigInteger.ONE]]]]
retu... | Keyword[public] identifier[List] operator[<] identifier[E] operator[>] identifier[next] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[numLeft] operator[SEP] identifier[equals] operator[SEP] identifier[total] operator[SEP] operator[SEP] {
identifier[numLeft] operator[=] identifier[... |
protected void bindColumn(PersistentProperty property, PersistentProperty parentProperty,
Column column, ColumnConfig cc, String path, Table table, String sessionFactoryBeanName) {
if (cc != null) {
column.setComment(cc.getComment());
column.setDefaultValue... | class class_name[name] begin[{]
method[bindColumn, return_type[void], modifier[protected], parameter[property, parentProperty, column, cc, path, table, sessionFactoryBeanName]] begin[{]
if[binary_operation[member[.cc], !=, literal[null]]] begin[{]
call[column.setComment,... | Keyword[protected] Keyword[void] identifier[bindColumn] operator[SEP] identifier[PersistentProperty] identifier[property] , identifier[PersistentProperty] identifier[parentProperty] , identifier[Column] identifier[column] , identifier[ColumnConfig] identifier[cc] , identifier[String] identifier[path] , identifier[... |
public static WxOutMsg handle(WxInMsg msg, WxHandler handler) {
WxOutMsg out = null;
switch (WxMsgType.valueOf(msg.getMsgType())) {
case text:
out = handler.text(msg);
break;
case image:
out = handler.image(msg);
break;
case voice:
... | class class_name[name] begin[{]
method[handle, return_type[type[WxOutMsg]], modifier[public static], parameter[msg, handler]] begin[{]
local_variable[type[WxOutMsg], out]
SwitchStatement(cases=[SwitchStatementCase(case=['text'], statements=[StatementExpression(expression=Assignment(expressionl=... | Keyword[public] Keyword[static] identifier[WxOutMsg] identifier[handle] operator[SEP] identifier[WxInMsg] identifier[msg] , identifier[WxHandler] identifier[handler] operator[SEP] {
identifier[WxOutMsg] identifier[out] operator[=] Other[null] operator[SEP] Keyword[switch] operator[SEP] identifier[WxMsgType] ope... |
public long writeToTable(String datasetName, String tableName, String csvData)
throws IOException, InterruptedException, TimeoutException {
// [START ]
TableId tableId = TableId.of(datasetName, tableName);
WriteChannelConfiguration writeChannelConfiguration =
WriteChannelConfiguration.newBuild... | class class_name[name] begin[{]
method[writeToTable, return_type[type[long]], modifier[public], parameter[datasetName, tableName, csvData]] begin[{]
local_variable[type[TableId], tableId]
local_variable[type[WriteChannelConfiguration], writeChannelConfiguration]
local_variable[type[Tabl... | Keyword[public] Keyword[long] identifier[writeToTable] operator[SEP] identifier[String] identifier[datasetName] , identifier[String] identifier[tableName] , identifier[String] identifier[csvData] operator[SEP] Keyword[throws] identifier[IOException] , identifier[InterruptedException] , identifier[TimeoutException] ... |
Group getGroup(String id, AccessToken accessToken, String... attributes) {
return getResource(id, accessToken, attributes);
} | class class_name[name] begin[{]
method[getGroup, return_type[type[Group]], modifier[default], parameter[id, accessToken, attributes]] begin[{]
return[call[.getResource, parameter[member[.id], member[.accessToken], member[.attributes]]]]
end[}]
END[}] | identifier[Group] identifier[getGroup] operator[SEP] identifier[String] identifier[id] , identifier[AccessToken] identifier[accessToken] , identifier[String] operator[...] identifier[attributes] operator[SEP] {
Keyword[return] identifier[getResource] operator[SEP] identifier[id] , identifier[accessToken] , i... |
public CompositeGeneratorNode appendNewLine(final CompositeGeneratorNode parent, final String lineSeparator) {
List<IGeneratorNode> _children = parent.getChildren();
NewLineNode _newLineNode = new NewLineNode(lineSeparator, false);
_children.add(_newLineNode);
return parent;
} | class class_name[name] begin[{]
method[appendNewLine, return_type[type[CompositeGeneratorNode]], modifier[public], parameter[parent, lineSeparator]] begin[{]
local_variable[type[List], _children]
local_variable[type[NewLineNode], _newLineNode]
call[_children.add, parameter[membe... | Keyword[public] identifier[CompositeGeneratorNode] identifier[appendNewLine] operator[SEP] Keyword[final] identifier[CompositeGeneratorNode] identifier[parent] , Keyword[final] identifier[String] identifier[lineSeparator] operator[SEP] {
identifier[List] operator[<] identifier[IGeneratorNode] operator[>] identi... |
public static void cublasZhbmv(char uplo, int n, int k, cuDoubleComplex alpha, Pointer A, int lda, Pointer x, int incx, cuDoubleComplex beta, Pointer y, int incy)
{
cublasZhbmvNative(uplo, n, k, alpha, A, lda, x, incx, beta, y, incy);
checkResultBLAS();
} | class class_name[name] begin[{]
method[cublasZhbmv, return_type[void], modifier[public static], parameter[uplo, n, k, alpha, A, lda, x, incx, beta, y, incy]] begin[{]
call[.cublasZhbmvNative, parameter[member[.uplo], member[.n], member[.k], member[.alpha], member[.A], member[.lda], member[.x], ... | Keyword[public] Keyword[static] Keyword[void] identifier[cublasZhbmv] operator[SEP] Keyword[char] identifier[uplo] , Keyword[int] identifier[n] , Keyword[int] identifier[k] , identifier[cuDoubleComplex] identifier[alpha] , identifier[Pointer] identifier[A] , Keyword[int] identifier[lda] , identifier[Pointer] iden... |
public Edge edgeFromJson(final JSONObject json, final Vertex out, final Vertex in) throws IOException {
return this.edgeFromJson(json.toString(), out, in);
} | class class_name[name] begin[{]
method[edgeFromJson, return_type[type[Edge]], modifier[public], parameter[json, out, in]] begin[{]
return[THIS[call[None.edgeFromJson, parameter[call[json.toString, parameter[]], member[.out], member[.in]]]]]
end[}]
END[}] | Keyword[public] identifier[Edge] identifier[edgeFromJson] operator[SEP] Keyword[final] identifier[JSONObject] identifier[json] , Keyword[final] identifier[Vertex] identifier[out] , Keyword[final] identifier[Vertex] identifier[in] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] Keyword[t... |
public void forwardField(String sourceField, String targetField) {
TransformationStep step = new TransformationStep();
step.setTargetField(targetField);
step.setSourceFields(sourceField);
step.setOperationName("forward");
steps.add(step);
} | class class_name[name] begin[{]
method[forwardField, return_type[void], modifier[public], parameter[sourceField, targetField]] begin[{]
local_variable[type[TransformationStep], step]
call[step.setTargetField, parameter[member[.targetField]]]
call[step.setSourceFields, pa... | Keyword[public] Keyword[void] identifier[forwardField] operator[SEP] identifier[String] identifier[sourceField] , identifier[String] identifier[targetField] operator[SEP] {
identifier[TransformationStep] identifier[step] operator[=] Keyword[new] identifier[TransformationStep] operator[SEP] operator[SEP] operato... |
public final ListTransferRunsPagedResponse listTransferRuns(TransferConfigName parent) {
ListTransferRunsRequest request =
ListTransferRunsRequest.newBuilder()
.setParent(parent == null ? null : parent.toString())
.build();
return listTransferRuns(request);
} | class class_name[name] begin[{]
method[listTransferRuns, return_type[type[ListTransferRunsPagedResponse]], modifier[final public], parameter[parent]] begin[{]
local_variable[type[ListTransferRunsRequest], request]
return[call[.listTransferRuns, parameter[member[.request]]]]
end[}]
END[}] | Keyword[public] Keyword[final] identifier[ListTransferRunsPagedResponse] identifier[listTransferRuns] operator[SEP] identifier[TransferConfigName] identifier[parent] operator[SEP] {
identifier[ListTransferRunsRequest] identifier[request] operator[=] identifier[ListTransferRunsRequest] operator[SEP] identifier[ne... |
public char getChar(String key) {
String s = getString(key);
if (s == null || s.trim().length() == 0) {
return (char) 0;
} else {
return s.charAt(0);
}
} | class class_name[name] begin[{]
method[getChar, return_type[type[char]], modifier[public], parameter[key]] begin[{]
local_variable[type[String], s]
if[binary_operation[binary_operation[member[.s], ==, literal[null]], ||, binary_operation[call[s.trim, parameter[]], ==, literal[0]]]] begi... | Keyword[public] Keyword[char] identifier[getChar] operator[SEP] identifier[String] identifier[key] operator[SEP] {
identifier[String] identifier[s] operator[=] identifier[getString] operator[SEP] identifier[key] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[s] operator[==] Other[null] operator... |
private void insert(Model target, BioPAXElement bpe)
{
// do nothing if you already inserted this
if (!target.contains(bpe))
{
//if there is an identical (in fact, "equal") object
BioPAXElement ibpe = target.getByID(bpe.getUri());
if (ibpe != null && ibpe.equals(bpe))
/* - ibpe.equals(bpe) can be 'fa... | class class_name[name] begin[{]
method[insert, return_type[void], modifier[private], parameter[target, bpe]] begin[{]
if[call[target.contains, parameter[member[.bpe]]]] begin[{]
local_variable[type[BioPAXElement], ibpe]
if[binary_operation[binary_operation[me... | Keyword[private] Keyword[void] identifier[insert] operator[SEP] identifier[Model] identifier[target] , identifier[BioPAXElement] identifier[bpe] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[target] operator[SEP] identifier[contains] operator[SEP] identifier[bpe] operator[SEP] operator[SEP] ... |
private InputStream getInputStream(String url) throws Exception {
HttpGet getMethod = new HttpGet(url);
DefaultHttpClient client = new DefaultHttpClient(m_cManager);
client.getParams().setIntParameter(CoreConnectionPNames.CONNECTION_TIMEOUT, TIMEOUT_SECONDS * 1000);
UsernamePasswordCrede... | class class_name[name] begin[{]
method[getInputStream, return_type[type[InputStream]], modifier[private], parameter[url]] begin[{]
local_variable[type[HttpGet], getMethod]
local_variable[type[DefaultHttpClient], client]
call[client.getParams, parameter[]]
local_variable[... | Keyword[private] identifier[InputStream] identifier[getInputStream] operator[SEP] identifier[String] identifier[url] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[HttpGet] identifier[getMethod] operator[=] Keyword[new] identifier[HttpGet] operator[SEP] identifier[url] operator[SEP] operator[SE... |
public void setClasspath (Path path)
{
_cloader = ClasspathUtils.getClassLoaderForPath(getProject(), path, "narya");
// set the parent of the classloader to be the classloader used to load this task, rather
// than the classloader used to load Ant, so that we have access to Narya classes li... | class class_name[name] begin[{]
method[setClasspath, return_type[void], modifier[public], parameter[path]] begin[{]
assign[member[._cloader], call[ClasspathUtils.getClassLoaderForPath, parameter[call[.getProject, parameter[]], member[.path], literal["narya"]]]]
Cast(expression=M... | Keyword[public] Keyword[void] identifier[setClasspath] operator[SEP] identifier[Path] identifier[path] operator[SEP] {
identifier[_cloader] operator[=] identifier[ClasspathUtils] operator[SEP] identifier[getClassLoaderForPath] operator[SEP] identifier[getProject] operator[SEP] operator[SEP] , identifier[path] ,... |
public void addRelation() {
try {
if (m_throwable != null) {
// relation data is corrupt, ignore relation
if (LOG.isWarnEnabled()) {
LOG.warn(
Messages.get().getBundle().key(
Messages.LOG_IMPORTE... | class class_name[name] begin[{]
method[addRelation, return_type[void], modifier[public], parameter[]] begin[{]
TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=m_throwable, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), operandr=Literal(po... | Keyword[public] Keyword[void] identifier[addRelation] operator[SEP] operator[SEP] {
Keyword[try] {
Keyword[if] operator[SEP] identifier[m_throwable] operator[!=] Other[null] operator[SEP] {
Keyword[if] operator[SEP] identifier[LOG] operator[SEP] identifier[isWarnEnabled] operator[SEP] o... |
String getDocumentationDir() {
String baseDir = project.getBuild().getDirectory();
if (baseDir == null || new File(baseDir).exists()) {
baseDir = project.getBasedir().getAbsolutePath();
baseDir = baseDir + "/target";
if (!new File(baseDir).exists()) {
... | class class_name[name] begin[{]
method[getDocumentationDir, return_type[type[String]], modifier[default], parameter[]] begin[{]
local_variable[type[String], baseDir]
if[binary_operation[binary_operation[member[.baseDir], ==, literal[null]], ||, ClassCreator(arguments=[MemberReference(me... | identifier[String] identifier[getDocumentationDir] operator[SEP] operator[SEP] {
identifier[String] identifier[baseDir] operator[=] identifier[project] operator[SEP] identifier[getBuild] operator[SEP] operator[SEP] operator[SEP] identifier[getDirectory] operator[SEP] operator[SEP] operator[SEP] Keyword[if] opera... |
public boolean add(Object obj) {
if (obj == null) {
obj = NULL;
}
Entry tab[] = mTable;
int hash = hashCode(obj);
int index = (hash & 0x7FFFFFFF) % tab.length;
for (Entry e = tab[index], prev = null; e != null; e = e.mNext) {
Object iobj = e.get(... | class class_name[name] begin[{]
method[add, return_type[type[boolean]], modifier[public], parameter[obj]] begin[{]
if[binary_operation[member[.obj], ==, literal[null]]] begin[{]
assign[member[.obj], member[.NULL]]
else begin[{]
None
end[}]
local_v... | Keyword[public] Keyword[boolean] identifier[add] operator[SEP] identifier[Object] identifier[obj] operator[SEP] {
Keyword[if] operator[SEP] identifier[obj] operator[==] Other[null] operator[SEP] {
identifier[obj] operator[=] identifier[NULL] operator[SEP]
}
identifier[Entry] identifier[t... |
@Override
public void visitClassContext(ClassContext classContext) {
try {
classVersion = classContext.getJavaClass().getMajor();
if (classVersion >= Const.MAJOR_1_4) {
stack = new OpcodeStack();
super.visitClassContext(classContext);
}
... | class class_name[name] begin[{]
method[visitClassContext, return_type[void], modifier[public], parameter[classContext]] begin[{]
TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(member=classVersion, postfix_operators=[], prefix_operators=[], qualifier=, selector... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[visitClassContext] operator[SEP] identifier[ClassContext] identifier[classContext] operator[SEP] {
Keyword[try] {
identifier[classVersion] operator[=] identifier[classContext] operator[SEP] identifier[getJavaClass] operator[SE... |
protected boolean isParentAnnotatedWithTraceeContextProvider(final Element element) {
Element parentElement = element.getEnclosingElement();
if (parentElement == null || parentElement.getKind() != ElementKind.CLASS
|| !isTypeAnnotatedWithTraceeContextProvider((TypeElement) parentElement... | class class_name[name] begin[{]
method[isParentAnnotatedWithTraceeContextProvider, return_type[type[boolean]], modifier[protected], parameter[element]] begin[{]
local_variable[type[Element], parentElement]
if[binary_operation[binary_operation[binary_operation[member[.parentElement], ==,... | Keyword[protected] Keyword[boolean] identifier[isParentAnnotatedWithTraceeContextProvider] operator[SEP] Keyword[final] identifier[Element] identifier[element] operator[SEP] {
identifier[Element] identifier[parentElement] operator[=] identifier[element] operator[SEP] identifier[getEnclosingElement] operator[SEP]... |
private void appendLinebreaks(Tag tag, boolean open) {
String name = tag.getTagName();
int pos = TAG_LIST.indexOf(name);
switch (pos) {
case 0: // H1
setMarker("=", open);
setIndentation(2, open);
appendLinebreak(2);
b... | class class_name[name] begin[{]
method[appendLinebreaks, return_type[void], modifier[private], parameter[tag, open]] begin[{]
local_variable[type[String], name]
local_variable[type[int], pos]
SwitchStatement(cases=[SwitchStatementCase(case=[Literal(postfix_operators=[], prefix_operators... | Keyword[private] Keyword[void] identifier[appendLinebreaks] operator[SEP] identifier[Tag] identifier[tag] , Keyword[boolean] identifier[open] operator[SEP] {
identifier[String] identifier[name] operator[=] identifier[tag] operator[SEP] identifier[getTagName] operator[SEP] operator[SEP] operator[SEP] Keyword[int... |
public Set<Explanation<OWLAxiom>> getExplanations(OWLAxiom entailment, int limit) throws ExplanationException {
OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
SyntacticLocalityModuleExtractor extractor = new SyntacticLocalityModuleExtractor(manager, (OWLOntology) null, workingAxioms... | class class_name[name] begin[{]
method[getExplanations, return_type[type[Set]], modifier[public], parameter[entailment, limit]] begin[{]
local_variable[type[OWLOntologyManager], manager]
local_variable[type[SyntacticLocalityModuleExtractor], extractor]
assign[member[.module], ca... | Keyword[public] identifier[Set] operator[<] identifier[Explanation] operator[<] identifier[OWLAxiom] operator[>] operator[>] identifier[getExplanations] operator[SEP] identifier[OWLAxiom] identifier[entailment] , Keyword[int] identifier[limit] operator[SEP] Keyword[throws] identifier[ExplanationException] {
ide... |
private Serializable readContent(File file, ExportFileType exportFileType, Logger logWriter)
throws IOException
{
String filePath = file.getAbsolutePath();
logWriter.info("reading "+filePath);
switch(exportFileType)
{
case gfd: return IO.readBinaryFile(file);
case json: return IO.re... | class class_name[name] begin[{]
method[readContent, return_type[type[Serializable]], modifier[private], parameter[file, exportFileType, logWriter]] begin[{]
local_variable[type[String], filePath]
call[logWriter.info, parameter[binary_operation[literal["reading "], +, member[.filePath]]]... | Keyword[private] identifier[Serializable] identifier[readContent] operator[SEP] identifier[File] identifier[file] , identifier[ExportFileType] identifier[exportFileType] , identifier[Logger] identifier[logWriter] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[String] identifier[filePath] op... |
public PhotoList<Photo> getNotInSet(int perPage, int page) throws FlickrException {
PhotoList<Photo> photos = new PhotoList<Photo>();
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", PhotosInterface.METHOD_GET_NOT_IN_SET);
RequestContext re... | class class_name[name] begin[{]
method[getNotInSet, return_type[type[PhotoList]], modifier[public], parameter[perPage, page]] begin[{]
local_variable[type[PhotoList], photos]
local_variable[type[Map], parameters]
call[parameters.put, parameter[literal["method"], member[PhotosInt... | Keyword[public] identifier[PhotoList] operator[<] identifier[Photo] operator[>] identifier[getNotInSet] operator[SEP] Keyword[int] identifier[perPage] , Keyword[int] identifier[page] operator[SEP] Keyword[throws] identifier[FlickrException] {
identifier[PhotoList] operator[<] identifier[Photo] operator[>] ident... |
protected static boolean createLoggingAction(final Logger logger, final Logger auditor, final TransactionLogger instance) {
TransactionLogger oldInstance = getInstance();
if (oldInstance == null || oldInstance.finished) {
if(loggingKeys == null) {
synchronized (TransactionLogger.class) {
... | class class_name[name] begin[{]
method[createLoggingAction, return_type[type[boolean]], modifier[static protected], parameter[logger, auditor, instance]] begin[{]
local_variable[type[TransactionLogger], oldInstance]
if[binary_operation[binary_operation[member[.oldInstance], ==, literal[... | Keyword[protected] Keyword[static] Keyword[boolean] identifier[createLoggingAction] operator[SEP] Keyword[final] identifier[Logger] identifier[logger] , Keyword[final] identifier[Logger] identifier[auditor] , Keyword[final] identifier[TransactionLogger] identifier[instance] operator[SEP] {
identifier[Transacti... |
public List<Destination> getDestinations() {
List<Destination> destinations = new ArrayList<Destination>();
Iterator<JMSDestination> destinationIterator =
jmsDestinations.values().iterator();
while(destinationIterator.hasNext()) {
destinations.add(destinationIterator.next... | class class_name[name] begin[{]
method[getDestinations, return_type[type[List]], modifier[public], parameter[]] begin[{]
local_variable[type[List], destinations]
local_variable[type[Iterator], destinationIterator]
while[call[destinationIterator.hasNext, parameter[]]] begin[{]
... | Keyword[public] identifier[List] operator[<] identifier[Destination] operator[>] identifier[getDestinations] operator[SEP] operator[SEP] {
identifier[List] operator[<] identifier[Destination] operator[>] identifier[destinations] operator[=] Keyword[new] identifier[ArrayList] operator[<] identifier[Destination] o... |
protected base_resource[] get_nitro_bulk_response(nitro_service service, String response) throws Exception
{
syslog_ui_cmd_responses result = (syslog_ui_cmd_responses) service.get_payload_formatter().string_to_resource(syslog_ui_cmd_responses.class, response);
if(result.errorcode != 0)
{
if (result.error... | class class_name[name] begin[{]
method[get_nitro_bulk_response, return_type[type[base_resource]], modifier[protected], parameter[service, response]] begin[{]
local_variable[type[syslog_ui_cmd_responses], result]
if[binary_operation[member[result.errorcode], !=, literal[0]]] begin[{]
... | Keyword[protected] identifier[base_resource] operator[SEP] operator[SEP] identifier[get_nitro_bulk_response] operator[SEP] identifier[nitro_service] identifier[service] , identifier[String] identifier[response] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[syslog_ui_cmd_responses] identifier[... |
public List<CorporationContractsResponse> getCorporationsCorporationIdContracts(Integer corporationId,
String datasource, String ifNoneMatch, Integer page, String token) throws ApiException {
ApiResponse<List<CorporationContractsResponse>> resp = getCorporationsCorporationIdContractsWithHttpInfo(
... | class class_name[name] begin[{]
method[getCorporationsCorporationIdContracts, return_type[type[List]], modifier[public], parameter[corporationId, datasource, ifNoneMatch, page, token]] begin[{]
local_variable[type[ApiResponse], resp]
return[call[resp.getData, parameter[]]]
end[}]
END[}] | Keyword[public] identifier[List] operator[<] identifier[CorporationContractsResponse] operator[>] identifier[getCorporationsCorporationIdContracts] operator[SEP] identifier[Integer] identifier[corporationId] , identifier[String] identifier[datasource] , identifier[String] identifier[ifNoneMatch] , identifier[Integer... |
protected void enableConsumers(List<ConsumerHolder> consumerHolders) throws IOException {
checkPreconditions(consumerHolders);
try {
for (ConsumerHolder consumerHolder : consumerHolders) {
consumerHolder.enable();
}
} catch (IOException e) {
... | class class_name[name] begin[{]
method[enableConsumers, return_type[void], modifier[protected], parameter[consumerHolders]] begin[{]
call[.checkPreconditions, parameter[member[.consumerHolders]]]
TryStatement(block=[ForStatement(body=BlockStatement(label=None, statements=[StatementExpre... | Keyword[protected] Keyword[void] identifier[enableConsumers] operator[SEP] identifier[List] operator[<] identifier[ConsumerHolder] operator[>] identifier[consumerHolders] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[checkPreconditions] operator[SEP] identifier[consumerHolders] operator[SEP]... |
public List<MarketOrdersResponse> getMarketsRegionIdOrders(String orderType, Integer regionId, String datasource,
String ifNoneMatch, Integer page, Integer typeId) throws ApiException {
ApiResponse<List<MarketOrdersResponse>> resp = getMarketsRegionIdOrdersWithHttpInfo(orderType, regionId,
... | class class_name[name] begin[{]
method[getMarketsRegionIdOrders, return_type[type[List]], modifier[public], parameter[orderType, regionId, datasource, ifNoneMatch, page, typeId]] begin[{]
local_variable[type[ApiResponse], resp]
return[call[resp.getData, parameter[]]]
end[}]
END[}] | Keyword[public] identifier[List] operator[<] identifier[MarketOrdersResponse] operator[>] identifier[getMarketsRegionIdOrders] operator[SEP] identifier[String] identifier[orderType] , identifier[Integer] identifier[regionId] , identifier[String] identifier[datasource] , identifier[String] identifier[ifNoneMatch] , ... |
public static VoltTable getPartitionKeys(TheHashinator hashinator, VoltType type) {
// get partitionKeys response table so we can copy it
final VoltTable partitionKeys;
switch (type) {
case INTEGER:
partitionKeys = hashinator.m_integerPartitionKeys.get();
... | class class_name[name] begin[{]
method[getPartitionKeys, return_type[type[VoltTable]], modifier[public static], parameter[hashinator, type]] begin[{]
local_variable[type[VoltTable], partitionKeys]
SwitchStatement(cases=[SwitchStatementCase(case=['INTEGER'], statements=[StatementExpression(expre... | Keyword[public] Keyword[static] identifier[VoltTable] identifier[getPartitionKeys] operator[SEP] identifier[TheHashinator] identifier[hashinator] , identifier[VoltType] identifier[type] operator[SEP] {
Keyword[final] identifier[VoltTable] identifier[partitionKeys] operator[SEP] Keyword[switch] operator[SEP] ide... |
public static void export(Descriptor desc, PrintStream outs, String[] excludes, CFMetaData metadata) throws IOException
{
export(SSTableReader.open(desc), outs, excludes, metadata);
} | class class_name[name] begin[{]
method[export, return_type[void], modifier[public static], parameter[desc, outs, excludes, metadata]] begin[{]
call[.export, parameter[call[SSTableReader.open, parameter[member[.desc]]], member[.outs], member[.excludes], member[.metadata]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[void] identifier[export] operator[SEP] identifier[Descriptor] identifier[desc] , identifier[PrintStream] identifier[outs] , identifier[String] operator[SEP] operator[SEP] identifier[excludes] , identifier[CFMetaData] identifier[metadata] operator[SEP] Keyword[throws] identifie... |
public final void mT__65() throws RecognitionException {
try {
int _type = T__65;
int _channel = DEFAULT_TOKEN_CHANNEL;
// InternalPureXbase.g:63:7: ( 'case' )
// InternalPureXbase.g:63:9: 'case'
{
match("case");
}
... | class class_name[name] begin[{]
method[mT__65, return_type[void], modifier[final public], parameter[]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MemberReference(member=T__65, postfix_operators=[], prefix_operators=[]... | Keyword[public] Keyword[final] Keyword[void] identifier[mT__65] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] {
Keyword[try] {
Keyword[int] identifier[_type] operator[=] identifier[T__65] operator[SEP] Keyword[int] identifier[_channel] operator[=] identifier[DEFAULT_TOKE... |
@SuppressWarnings("unchecked")
public static UniversalIdIntQueueMessage newInstance() {
Date now = new Date();
UniversalIdIntQueueMessage msg = new UniversalIdIntQueueMessage();
msg.setQueueTimestamp(now).setNumRequeues(0).setId(QueueUtils.IDGEN.generateId64())
.setTimestamp(... | class class_name[name] begin[{]
method[newInstance, return_type[type[UniversalIdIntQueueMessage]], modifier[public static], parameter[]] begin[{]
local_variable[type[Date], now]
local_variable[type[UniversalIdIntQueueMessage], msg]
call[msg.setQueueTimestamp, parameter[member[.n... | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[static] identifier[UniversalIdIntQueueMessage] identifier[newInstance] operator[SEP] operator[SEP] {
identifier[Date] identifier[now] operator[=] Keyword[new] identifier[Date] operator[SEP] operator[SEP... |
public R setTags(List<String> tags) {
JsonArray jsonArray = new JsonArray();
for (String s : tags) {
jsonArray.add(s);
}
mBodyMap.put(BoxItem.FIELD_TAGS, jsonArray);
return (R) this;
} | class class_name[name] begin[{]
method[setTags, return_type[type[R]], modifier[public], parameter[tags]] begin[{]
local_variable[type[JsonArray], jsonArray]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member... | Keyword[public] identifier[R] identifier[setTags] operator[SEP] identifier[List] operator[<] identifier[String] operator[>] identifier[tags] operator[SEP] {
identifier[JsonArray] identifier[jsonArray] operator[=] Keyword[new] identifier[JsonArray] operator[SEP] operator[SEP] operator[SEP] Keyword[for] operator[S... |
public static <T extends FrameJob> T hygiene(T job) {
job.source = null;
return job;
} | class class_name[name] begin[{]
method[hygiene, return_type[type[T]], modifier[public static], parameter[job]] begin[{]
assign[member[job.source], literal[null]]
return[member[.job]]
end[}]
END[}] | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[FrameJob] operator[>] identifier[T] identifier[hygiene] operator[SEP] identifier[T] identifier[job] operator[SEP] {
identifier[job] operator[SEP] identifier[source] operator[=] Other[null] operator[SEP] Keyword[return] identifi... |
public QueryExpression eq(String propertyName,String value)
{
return new SimpleQueryExpression(propertyName, ComparisonOperator.EQUAL,wrap(value));
} | class class_name[name] begin[{]
method[eq, return_type[type[QueryExpression]], modifier[public], parameter[propertyName, value]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=propertyName, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(member=EQUA... | Keyword[public] identifier[QueryExpression] identifier[eq] operator[SEP] identifier[String] identifier[propertyName] , identifier[String] identifier[value] operator[SEP] {
Keyword[return] Keyword[new] identifier[SimpleQueryExpression] operator[SEP] identifier[propertyName] , identifier[ComparisonOperator] oper... |
public static OutputStream getFileOutputStream(String filename) throws IOException {
OutputStream out = new FileOutputStream(filename);
if (filename.endsWith(".gz")) {
out = new GZIPOutputStream(out);
} else if (filename.endsWith(".bz2")) {
//out = new CBZip2OutputStream(out);
out = ... | class class_name[name] begin[{]
method[getFileOutputStream, return_type[type[OutputStream]], modifier[public static], parameter[filename]] begin[{]
local_variable[type[OutputStream], out]
if[call[filename.endsWith, parameter[literal[".gz"]]]] begin[{]
assign[memb... | Keyword[public] Keyword[static] identifier[OutputStream] identifier[getFileOutputStream] operator[SEP] identifier[String] identifier[filename] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[OutputStream] identifier[out] operator[=] Keyword[new] identifier[FileOutputStream] operator[SEP] ident... |
public java.util.List<ResourceKey> getFailedItems() {
if (failedItems == null) {
failedItems = new com.amazonaws.internal.SdkInternalList<ResourceKey>();
}
return failedItems;
} | class class_name[name] begin[{]
method[getFailedItems, return_type[type[java]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.failedItems], ==, literal[null]]] begin[{]
assign[member[.failedItems], ClassCreator(arguments=[], body=None, constructor_t... | Keyword[public] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[List] operator[<] identifier[ResourceKey] operator[>] identifier[getFailedItems] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[failedItems] operator[==] Other[null] operator[SEP] {
identifier[... |
public void stop() {
if (stopRequested) {
return;
}
stopRequested = true;
running = false;
if (server != null) server.stop();
if (triggerThread != null) {
triggerThread.interrupt();
triggerMonitor = null;
}
if (urfThread != null) {
urfThread.interrupt();
urf... | class class_name[name] begin[{]
method[stop, return_type[void], modifier[public], parameter[]] begin[{]
if[member[.stopRequested]] begin[{]
return[None]
else begin[{]
None
end[}]
assign[member[.stopRequested], literal[true]]
assign[mem... | Keyword[public] Keyword[void] identifier[stop] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[stopRequested] operator[SEP] {
Keyword[return] operator[SEP]
}
identifier[stopRequested] operator[=] literal[boolean] operator[SEP] identifier[running] operator[=] literal[bo... |
public static <T extends ParameterDescription> ElementMatcher.Junction<T> is(ParameterDescription.InDefinedShape parameter) {
return definedParameter(new EqualityMatcher<ParameterDescription.InDefinedShape>(parameter));
} | class class_name[name] begin[{]
method[is, return_type[type[ElementMatcher]], modifier[public static], parameter[parameter]] begin[{]
return[call[.definedParameter, parameter[ClassCreator(arguments=[MemberReference(member=parameter, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])],... | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[ParameterDescription] operator[>] identifier[ElementMatcher] operator[SEP] identifier[Junction] operator[<] identifier[T] operator[>] identifier[is] operator[SEP] identifier[ParameterDescription] operator[SEP] identifier[InDefinedShap... |
public static MutableInodeFile fromJournalEntry(InodeFileEntry entry) {
// If journal entry has no mode set, set default mode for backwards-compatibility.
MutableInodeFile ret = new MutableInodeFile(BlockId.getContainerId(entry.getId()))
.setName(entry.getName())
.setBlockIds(entry.getBlocksList... | class class_name[name] begin[{]
method[fromJournalEntry, return_type[type[MutableInodeFile]], modifier[public static], parameter[entry]] begin[{]
local_variable[type[MutableInodeFile], ret]
if[call[entry.hasAcl, parameter[]]] begin[{]
assign[member[ret.mAcl], cal... | Keyword[public] Keyword[static] identifier[MutableInodeFile] identifier[fromJournalEntry] operator[SEP] identifier[InodeFileEntry] identifier[entry] operator[SEP] {
identifier[MutableInodeFile] identifier[ret] operator[=] Keyword[new] identifier[MutableInodeFile] operator[SEP] identifier[BlockId] operator[SEP] i... |
protected Object readResolve() throws ObjectStreamException {
try {
if (type == Type.SECRET && RAW.equals(format)) {
return new SecretKeySpec(encoded, algorithm);
} else if (type == Type.PUBLIC && X509.equals(format)) {
KeyFactory f = KeyFactory.getInstanc... | class class_name[name] begin[{]
method[readResolve, return_type[type[Object]], modifier[protected], parameter[]] begin[{]
TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=BinaryOperation(operandl=MemberReference(member=type, postfix_operators=[], prefix_operators=[], qualifier=, selec... | Keyword[protected] identifier[Object] identifier[readResolve] operator[SEP] operator[SEP] Keyword[throws] identifier[ObjectStreamException] {
Keyword[try] {
Keyword[if] operator[SEP] identifier[type] operator[==] identifier[Type] operator[SEP] identifier[SECRET] operator[&&] identifier[RAW] operator[S... |
@Override
public EEnum getIfcBuildingElementPartTypeEnum() {
if (ifcBuildingElementPartTypeEnumEEnum == null) {
ifcBuildingElementPartTypeEnumEEnum = (EEnum) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(924);
}
return ifcBuildingElementPartTypeEnumEEnum;
} | class class_name[name] begin[{]
method[getIfcBuildingElementPartTypeEnum, return_type[type[EEnum]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.ifcBuildingElementPartTypeEnumEEnum], ==, literal[null]]] begin[{]
assign[member[.ifcBuildingElementPar... | annotation[@] identifier[Override] Keyword[public] identifier[EEnum] identifier[getIfcBuildingElementPartTypeEnum] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[ifcBuildingElementPartTypeEnumEEnum] operator[==] Other[null] operator[SEP] {
identifier[ifcBuildingElementPartTypeEnumE... |
@Override
public void set(DataStoreSource source, String key, Object value) {
SetRequest request = new SetRequest(source, Action.SET_SOURCE,
messageId, clientId, 0, 0, 0, key, serializer.serialize(value).toString());
send(request);
} | class class_name[name] begin[{]
method[set, return_type[void], modifier[public], parameter[source, key, value]] begin[{]
local_variable[type[SetRequest], request]
call[.send, parameter[member[.request]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[set] operator[SEP] identifier[DataStoreSource] identifier[source] , identifier[String] identifier[key] , identifier[Object] identifier[value] operator[SEP] {
identifier[SetRequest] identifier[request] operator[=] Keyword[new] identifie... |
public void orderedCopy(SegmentedByteArray src, long srcPos, long destPos, long length) {
int segmentLength = 1 << log2OfSegmentSize;
int currentSegment = (int)(destPos >>> log2OfSegmentSize);
int segmentStartPos = (int)(destPos & bitmask);
int remainingBytesInSegment = segmentLength - s... | class class_name[name] begin[{]
method[orderedCopy, return_type[void], modifier[public], parameter[src, srcPos, destPos, length]] begin[{]
local_variable[type[int], segmentLength]
local_variable[type[int], currentSegment]
local_variable[type[int], segmentStartPos]
local_variable... | Keyword[public] Keyword[void] identifier[orderedCopy] operator[SEP] identifier[SegmentedByteArray] identifier[src] , Keyword[long] identifier[srcPos] , Keyword[long] identifier[destPos] , Keyword[long] identifier[length] operator[SEP] {
Keyword[int] identifier[segmentLength] operator[=] Other[1] operator[<<] ... |
@FFDCIgnore(value = { IndexOutOfBoundsException.class }) // Liberty Change
private static Object injectIntoCollectionOrArray(Class<?> rawType,
Type genericType,
Annotation[] paramAnns,
... | class class_name[name] begin[{]
method[injectIntoCollectionOrArray, return_type[type[Object]], modifier[private static], parameter[rawType, genericType, paramAnns, values, isbean, decoded, pathParam, message]] begin[{]
local_variable[type[ParamConverter], pm]
if[binary_operation[member[... | annotation[@] identifier[FFDCIgnore] operator[SEP] identifier[value] operator[=] {
identifier[IndexOutOfBoundsException] operator[SEP] Keyword[class]
} operator[SEP] Keyword[private] Keyword[static] identifier[Object] identifier[injectIntoCollectionOrArray] operator[SEP] identifier[Class] operator[<] operator... |
public SourceSchema withRecordColumns(RecordColumn... recordColumns) {
if (this.recordColumns == null) {
setRecordColumns(new java.util.ArrayList<RecordColumn>(recordColumns.length));
}
for (RecordColumn ele : recordColumns) {
this.recordColumns.add(ele);
}
... | class class_name[name] begin[{]
method[withRecordColumns, return_type[type[SourceSchema]], modifier[public], parameter[recordColumns]] begin[{]
if[binary_operation[THIS[member[None.recordColumns]], ==, literal[null]]] begin[{]
call[.setRecordColumns, parameter[ClassCreat... | Keyword[public] identifier[SourceSchema] identifier[withRecordColumns] operator[SEP] identifier[RecordColumn] operator[...] identifier[recordColumns] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[recordColumns] operator[==] Other[null] operator[SEP] {
identifier[setR... |
public BeanO addBean(BeanO beanO, ContainerTx containerTx) throws DuplicateKeyException, RemoteException {
return activator.addBean(containerTx, beanO);
} | class class_name[name] begin[{]
method[addBean, return_type[type[BeanO]], modifier[public], parameter[beanO, containerTx]] begin[{]
return[call[activator.addBean, parameter[member[.containerTx], member[.beanO]]]]
end[}]
END[}] | Keyword[public] identifier[BeanO] identifier[addBean] operator[SEP] identifier[BeanO] identifier[beanO] , identifier[ContainerTx] identifier[containerTx] operator[SEP] Keyword[throws] identifier[DuplicateKeyException] , identifier[RemoteException] {
Keyword[return] identifier[activator] operator[SEP] identifie... |
public static AuthenticationData createAuthenticationData(Certificate[] certs, UserRegistry userRegistry) {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
SibTr.entry(tc, CLASS_NAME + "createAuthenticationData", certs);
}
AuthenticationData authData = new WSAuthen... | class class_name[name] begin[{]
method[createAuthenticationData, return_type[type[AuthenticationData]], modifier[public static], parameter[certs, userRegistry]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{... | Keyword[public] Keyword[static] identifier[AuthenticationData] identifier[createAuthenticationData] operator[SEP] identifier[Certificate] operator[SEP] operator[SEP] identifier[certs] , identifier[UserRegistry] identifier[userRegistry] operator[SEP] {
Keyword[if] operator[SEP] identifier[TraceComponent] operato... |
public StringClauses replace(Enum key, StringClauses newValue) {
return replace(key.name(), newValue);
} | class class_name[name] begin[{]
method[replace, return_type[type[StringClauses]], modifier[public], parameter[key, newValue]] begin[{]
return[call[.replace, parameter[call[key.name, parameter[]], member[.newValue]]]]
end[}]
END[}] | Keyword[public] identifier[StringClauses] identifier[replace] operator[SEP] identifier[Enum] identifier[key] , identifier[StringClauses] identifier[newValue] operator[SEP] {
Keyword[return] identifier[replace] operator[SEP] identifier[key] operator[SEP] identifier[name] operator[SEP] operator[SEP] , identifier... |
public boolean createIfNotFoundError(DBException ex)
throws DBException
{
if (ex.getErrorCode() == DBConstants.FILE_NOT_FOUND)
if (this.getRecord() != null)
if ((this.getRecord().getOpenMode() & DBConstants.OPEN_DONT_CREATE) == 0)
{
boolean loadInitial... | class class_name[name] begin[{]
method[createIfNotFoundError, return_type[type[boolean]], modifier[public], parameter[ex]] begin[{]
if[binary_operation[call[ex.getErrorCode, parameter[]], ==, member[DBConstants.FILE_NOT_FOUND]]] begin[{]
if[binary_operation[THIS[call[None.getRecord,... | Keyword[public] Keyword[boolean] identifier[createIfNotFoundError] operator[SEP] identifier[DBException] identifier[ex] operator[SEP] Keyword[throws] identifier[DBException] {
Keyword[if] operator[SEP] identifier[ex] operator[SEP] identifier[getErrorCode] operator[SEP] operator[SEP] operator[==] identifier[DBCon... |
public void build(final LNGIntVector ns) {
for (int i = 0; i < this.heap.size(); i++)
this.indices.set(this.heap.get(i), -1);
this.heap.clear();
for (int i = 0; i < ns.size(); i++) {
this.indices.set(ns.get(i), i);
this.heap.push(ns.get(i));
}
for (int i = this.heap.size() / 2 - 1;... | class class_name[name] begin[{]
method[build, return_type[void], modifier[public], parameter[ns]] begin[{]
ForStatement(body=StatementExpression(expression=This(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[MemberReference(member=indices, postfix_operators=None, prefix_operators... | Keyword[public] Keyword[void] identifier[build] operator[SEP] Keyword[final] identifier[LNGIntVector] identifier[ns] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] Keyword[this] operator[SEP] identifier[heap] operator[SEP] identi... |
protected Node getXPathResultNode(String select, Document document)
throws ConfigurationException, TransformerException, XpathException {
return getXPathResultAsDocument(select, document).getDocumentElement();
} | class class_name[name] begin[{]
method[getXPathResultNode, return_type[type[Node]], modifier[protected], parameter[select, document]] begin[{]
return[call[.getXPathResultAsDocument, parameter[member[.select], member[.document]]]]
end[}]
END[}] | Keyword[protected] identifier[Node] identifier[getXPathResultNode] operator[SEP] identifier[String] identifier[select] , identifier[Document] identifier[document] operator[SEP] Keyword[throws] identifier[ConfigurationException] , identifier[TransformerException] , identifier[XpathException] {
Keyword[return] ... |
public void setVspace(String vspace) {
_imageState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.VSPACE, vspace);
} | class class_name[name] begin[{]
method[setVspace, return_type[void], modifier[public], parameter[vspace]] begin[{]
call[_imageState.registerAttribute, parameter[member[AbstractHtmlState.ATTR_GENERAL], member[HtmlConstants.VSPACE], member[.vspace]]]
end[}]
END[}] | Keyword[public] Keyword[void] identifier[setVspace] operator[SEP] identifier[String] identifier[vspace] operator[SEP] {
identifier[_imageState] operator[SEP] identifier[registerAttribute] operator[SEP] identifier[AbstractHtmlState] operator[SEP] identifier[ATTR_GENERAL] , identifier[HtmlConstants] operator[SEP]... |
public void setMinimumDuration(@NotNull final Duration minimumDuration) {
if (minimumDuration.compareTo(MAXIMUM_DURATION) > 0) {
throw new IllegalArgumentException("The minimum duaration has to be smaller than 23:59:59.");
}
this.minimumDuration = durationToDate(minimumDuration);
... | class class_name[name] begin[{]
method[setMinimumDuration, return_type[void], modifier[public], parameter[minimumDuration]] begin[{]
if[binary_operation[call[minimumDuration.compareTo, parameter[member[.MAXIMUM_DURATION]]], >, literal[0]]] begin[{]
ThrowStatement(expression=ClassCre... | Keyword[public] Keyword[void] identifier[setMinimumDuration] operator[SEP] annotation[@] identifier[NotNull] Keyword[final] identifier[Duration] identifier[minimumDuration] operator[SEP] {
Keyword[if] operator[SEP] identifier[minimumDuration] operator[SEP] identifier[compareTo] operator[SEP] identifier[MAXIMUM_D... |
private boolean handleOverridesAndConflicts(JvmOperation operation, Multimap<String, AbstractResolvedOperation> processedOperations) {
String simpleName = operation.getSimpleName();
if (!processedOperations.containsKey(simpleName)) {
return true;
}
List<AbstractResolvedOperation> conflictingOperations = null... | class class_name[name] begin[{]
method[handleOverridesAndConflicts, return_type[type[boolean]], modifier[private], parameter[operation, processedOperations]] begin[{]
local_variable[type[String], simpleName]
if[call[processedOperations.containsKey, parameter[member[.simpleName]]]] begin... | Keyword[private] Keyword[boolean] identifier[handleOverridesAndConflicts] operator[SEP] identifier[JvmOperation] identifier[operation] , identifier[Multimap] operator[<] identifier[String] , identifier[AbstractResolvedOperation] operator[>] identifier[processedOperations] operator[SEP] {
identifier[String] ide... |
public com.google.api.ads.adwords.axis.v201809.rm.UserListClosingReason getClosingReason() {
return closingReason;
} | class class_name[name] begin[{]
method[getClosingReason, return_type[type[com]], modifier[public], parameter[]] begin[{]
return[member[.closingReason]]
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[rm] operator[SEP] identifier[UserListClosingReason] identifier[getClosi... |
public static void main(String... args) {
if (args.length == 0 || args[0].trim().isEmpty()) {
System.err.println("missing argument: loggly token\nsee http://loggly.com/docs/customer-token-authentication-token/");
System.exit(1);
}
final String TOKEN = args[0];
f... | class class_name[name] begin[{]
method[main, return_type[void], modifier[public static], parameter[args]] begin[{]
if[binary_operation[binary_operation[member[args.length], ==, literal[0]], ||, member[.args]]] begin[{]
call[System.err.println, parameter[literal["missing ... | Keyword[public] Keyword[static] Keyword[void] identifier[main] operator[SEP] identifier[String] operator[...] identifier[args] operator[SEP] {
Keyword[if] operator[SEP] identifier[args] operator[SEP] identifier[length] operator[==] Other[0] operator[||] identifier[args] operator[SEP] Other[0] operator[SEP] opera... |
public static SerializationContext getSerializationContext(RemoteCacheManager remoteCacheManager) {
Marshaller marshaller = remoteCacheManager.getMarshaller();
if (marshaller instanceof ProtoStreamMarshaller) {
return ((ProtoStreamMarshaller) marshaller).getSerializationContext();
}
thr... | class class_name[name] begin[{]
method[getSerializationContext, return_type[type[SerializationContext]], modifier[public static], parameter[remoteCacheManager]] begin[{]
local_variable[type[Marshaller], marshaller]
if[binary_operation[member[.marshaller], instanceof, type[ProtoStreamMar... | Keyword[public] Keyword[static] identifier[SerializationContext] identifier[getSerializationContext] operator[SEP] identifier[RemoteCacheManager] identifier[remoteCacheManager] operator[SEP] {
identifier[Marshaller] identifier[marshaller] operator[=] identifier[remoteCacheManager] operator[SEP] identifier[getMar... |
public Set<Node> querySelectorAll(String selectors) throws NodeSelectorException {
Assert.notNull(selectors, "selectors is null!");
List<List<Selector>> groups;
try {
Scanner scanner = new Scanner(selectors);
groups = scanner.scan();
} catch (ScannerExceptio... | class class_name[name] begin[{]
method[querySelectorAll, return_type[type[Set]], modifier[public], parameter[selectors]] begin[{]
call[Assert.notNull, parameter[member[.selectors], literal["selectors is null!"]]]
local_variable[type[List], groups]
TryStatement(block=[LocalVariab... | Keyword[public] identifier[Set] operator[<] identifier[Node] operator[>] identifier[querySelectorAll] operator[SEP] identifier[String] identifier[selectors] operator[SEP] Keyword[throws] identifier[NodeSelectorException] {
identifier[Assert] operator[SEP] identifier[notNull] operator[SEP] identifier[selectors] ,... |
public static Attachment writeAttachment(byte[] attachment, String title, String type) throws IOException {
String name = generateAttachmentName();
String extension = getExtensionByMimeType(type);
String source = name + extension;
File file = new File(getResultsDirectory(), source);
... | class class_name[name] begin[{]
method[writeAttachment, return_type[type[Attachment]], modifier[public static], parameter[attachment, title, type]] begin[{]
local_variable[type[String], name]
local_variable[type[String], extension]
local_variable[type[String], source]
local_vari... | Keyword[public] Keyword[static] identifier[Attachment] identifier[writeAttachment] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[attachment] , identifier[String] identifier[title] , identifier[String] identifier[type] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[Strin... |
@Override
public File decrypt(final File encrypted) throws Exception
{
if (decryptedFile == null)
{
final String filename = FilenameUtils.getBaseName(encrypted.getName());
decryptedFile = newDecryptedFile(encrypted.getParent(), filename + ".decrypted");
}
final FileOutputStream decryptedOut = new FileO... | class class_name[name] begin[{]
method[decrypt, return_type[type[File]], modifier[public], parameter[encrypted]] begin[{]
if[binary_operation[member[.decryptedFile], ==, literal[null]]] begin[{]
local_variable[type[String], filename]
assign[member[.decryptedF... | annotation[@] identifier[Override] Keyword[public] identifier[File] identifier[decrypt] operator[SEP] Keyword[final] identifier[File] identifier[encrypted] operator[SEP] Keyword[throws] identifier[Exception] {
Keyword[if] operator[SEP] identifier[decryptedFile] operator[==] Other[null] operator[SEP] {
... |
public Map<String, String> parse(Map<String, String> style) {
Map<String, String> mapRtn = new HashMap<String, String>();
String align = style.get(TEXT_ALIGN);
if (!ArrayUtils.contains(new String[] {LEFT, CENTER, RIGHT, JUSTIFY}, align)) {
align = LEFT;
}
mapRtn.put(TEXT_ALIGN, align);
... | class class_name[name] begin[{]
method[parse, return_type[type[Map]], modifier[public], parameter[style]] begin[{]
local_variable[type[Map], mapRtn]
local_variable[type[String], align]
if[call[ArrayUtils.contains, parameter[ArrayCreator(dimensions=[None], initializer=ArrayInitia... | Keyword[public] identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[parse] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[style] operator[SEP] {
identifier[Map] operator[<] identifier[String] , identifier[String] ... |
private CmsUUID maybeReplaceFormatter(CmsUUID formatterId) {
if (m_customReplacements != null) {
CmsUUID replacement = m_customReplacements.get(formatterId);
if (replacement != null) {
return replacement;
}
}
return formatterId;
} | class class_name[name] begin[{]
method[maybeReplaceFormatter, return_type[type[CmsUUID]], modifier[private], parameter[formatterId]] begin[{]
if[binary_operation[member[.m_customReplacements], !=, literal[null]]] begin[{]
local_variable[type[CmsUUID], replacement]
... | Keyword[private] identifier[CmsUUID] identifier[maybeReplaceFormatter] operator[SEP] identifier[CmsUUID] identifier[formatterId] operator[SEP] {
Keyword[if] operator[SEP] identifier[m_customReplacements] operator[!=] Other[null] operator[SEP] {
identifier[CmsUUID] identifier[replacement] operator[=] i... |
public ServiceFuture<List<P2SVpnServerConfigurationInner>> listByVirtualWanNextAsync(final String nextPageLink, final ServiceFuture<List<P2SVpnServerConfigurationInner>> serviceFuture, final ListOperationCallback<P2SVpnServerConfigurationInner> serviceCallback) {
return AzureServiceFuture.fromPageResponse(
... | class class_name[name] begin[{]
method[listByVirtualWanNextAsync, return_type[type[ServiceFuture]], modifier[public], parameter[nextPageLink, serviceFuture, serviceCallback]] begin[{]
return[call[AzureServiceFuture.fromPageResponse, parameter[call[.listByVirtualWanNextSinglePageAsync, parameter[member[... | Keyword[public] identifier[ServiceFuture] operator[<] identifier[List] operator[<] identifier[P2SVpnServerConfigurationInner] operator[>] operator[>] identifier[listByVirtualWanNextAsync] operator[SEP] Keyword[final] identifier[String] identifier[nextPageLink] , Keyword[final] identifier[ServiceFuture] operator[<] ide... |
protected Query[] buildPrefetchQueries(Collection owners, Collection children)
{
ClassDescriptor cld = getOwnerClassDescriptor();
Class topLevelClass = getBroker().getTopLevelClass(cld.getClassOfObject());
BrokerHelper helper = getBroker().serviceBrokerHelper();
Collection queri... | class class_name[name] begin[{]
method[buildPrefetchQueries, return_type[type[Query]], modifier[protected], parameter[owners, children]] begin[{]
local_variable[type[ClassDescriptor], cld]
local_variable[type[Class], topLevelClass]
local_variable[type[BrokerHelper], helper]
loca... | Keyword[protected] identifier[Query] operator[SEP] operator[SEP] identifier[buildPrefetchQueries] operator[SEP] identifier[Collection] identifier[owners] , identifier[Collection] identifier[children] operator[SEP] {
identifier[ClassDescriptor] identifier[cld] operator[=] identifier[getOwnerClassDescriptor] oper... |
@Override
public EClass getIfcCompressorType() {
if (ifcCompressorTypeEClass == null) {
ifcCompressorTypeEClass = (EClass) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(116);
}
return ifcCompressorTypeEClass;
} | class class_name[name] begin[{]
method[getIfcCompressorType, return_type[type[EClass]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.ifcCompressorTypeEClass], ==, literal[null]]] begin[{]
assign[member[.ifcCompressorTypeEClass], Cast(expression=Met... | annotation[@] identifier[Override] Keyword[public] identifier[EClass] identifier[getIfcCompressorType] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[ifcCompressorTypeEClass] operator[==] Other[null] operator[SEP] {
identifier[ifcCompressorTypeEClass] operator[=] operator[SEP] iden... |
public Observable<Object> addTermAsync(String listId, String term, String language) {
return addTermWithServiceResponseAsync(listId, term, language).map(new Func1<ServiceResponse<Object>, Object>() {
@Override
public Object call(ServiceResponse<Object> response) {
return ... | class class_name[name] begin[{]
method[addTermAsync, return_type[type[Observable]], modifier[public], parameter[listId, term, language]] begin[{]
return[call[.addTermWithServiceResponseAsync, parameter[member[.listId], member[.term], member[.language]]]]
end[}]
END[}] | Keyword[public] identifier[Observable] operator[<] identifier[Object] operator[>] identifier[addTermAsync] operator[SEP] identifier[String] identifier[listId] , identifier[String] identifier[term] , identifier[String] identifier[language] operator[SEP] {
Keyword[return] identifier[addTermWithServiceResponseAsy... |
@Handler
public void onConfigurationUpdate(ConfigurationUpdate event) {
event.values(componentPath()).ifPresent(values -> {
Optional.ofNullable(values.get("bufferSize")).ifPresent(
value -> setBufferSize(Integer.parseInt(value)));
});
} | class class_name[name] begin[{]
method[onConfigurationUpdate, return_type[void], modifier[public], parameter[event]] begin[{]
call[event.values, parameter[call[.componentPath, parameter[]]]]
end[}]
END[}] | annotation[@] identifier[Handler] Keyword[public] Keyword[void] identifier[onConfigurationUpdate] operator[SEP] identifier[ConfigurationUpdate] identifier[event] operator[SEP] {
identifier[event] operator[SEP] identifier[values] operator[SEP] identifier[componentPath] operator[SEP] operator[SEP] operator[SEP] op... |
public XFeatureCall createReferenceToThis() {
final XExpression expr = getXExpression();
XtendTypeDeclaration type = EcoreUtil2.getContainerOfType(expr, XtendTypeDeclaration.class);
JvmType jvmObject = getAssociatedElement(JvmType.class, type, expr.eResource());
final XFeatureCall thisFeature = XbaseFactory.eIN... | class class_name[name] begin[{]
method[createReferenceToThis, return_type[type[XFeatureCall]], modifier[public], parameter[]] begin[{]
local_variable[type[XExpression], expr]
local_variable[type[XtendTypeDeclaration], type]
local_variable[type[JvmType], jvmObject]
local_variable... | Keyword[public] identifier[XFeatureCall] identifier[createReferenceToThis] operator[SEP] operator[SEP] {
Keyword[final] identifier[XExpression] identifier[expr] operator[=] identifier[getXExpression] operator[SEP] operator[SEP] operator[SEP] identifier[XtendTypeDeclaration] identifier[type] operator[=] identifie... |
public void addGetTimeNano(long duration) {
if (unsupportCacheGetTotalTime.get() <= Long.MAX_VALUE - duration) {
unsupportCacheGetTotalTime.addAndGet(duration);
} else {
//counter full. Just reset.
clear();
unsupportCacheGetTotalTime.set(duration);
}
} | class class_name[name] begin[{]
method[addGetTimeNano, return_type[void], modifier[public], parameter[duration]] begin[{]
if[binary_operation[call[unsupportCacheGetTotalTime.get, parameter[]], <=, binary_operation[member[Long.MAX_VALUE], -, member[.duration]]]] begin[{]
... | Keyword[public] Keyword[void] identifier[addGetTimeNano] operator[SEP] Keyword[long] identifier[duration] operator[SEP] {
Keyword[if] operator[SEP] identifier[unsupportCacheGetTotalTime] operator[SEP] identifier[get] operator[SEP] operator[SEP] operator[<=] identifier[Long] operator[SEP] identifier[MAX_VALUE] op... |
public static Dependencies load(final File file) {
Utils4J.checkNotNull("file", file);
Utils4J.checkValidFile(file);
try {
final InputStream inputStream = new BufferedInputStream(new FileInputStream(file));
try {
return load(inputStream);
... | class class_name[name] begin[{]
method[load, return_type[type[Dependencies]], modifier[public static], parameter[file]] begin[{]
call[Utils4J.checkNotNull, parameter[literal["file"], member[.file]]]
call[Utils4J.checkValidFile, parameter[member[.file]]]
TryStatement(bloc... | Keyword[public] Keyword[static] identifier[Dependencies] identifier[load] operator[SEP] Keyword[final] identifier[File] identifier[file] operator[SEP] {
identifier[Utils4J] operator[SEP] identifier[checkNotNull] operator[SEP] literal[String] , identifier[file] operator[SEP] operator[SEP] identifier[Utils4J] ope... |
public void marshall(Deinterlacer deinterlacer, ProtocolMarshaller protocolMarshaller) {
if (deinterlacer == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(deinterlacer.getAlgorithm(), ALGORITHM_BIND... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[deinterlacer, protocolMarshaller]] begin[{]
if[binary_operation[member[.deinterlacer], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_opera... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[Deinterlacer] identifier[deinterlacer] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[deinterlacer] operator[==] Other[null] operator[SEP] {
Keyword[throw]... |
public static byte[] getGuidAsByteArray(final String GUID) {
final UUID uuid = UUID.fromString(GUID);
final ByteBuffer buff = ByteBuffer.wrap(new byte[16]);
buff.putLong(uuid.getMostSignificantBits());
buff.putLong(uuid.getLeastSignificantBits());
byte[] res = new byte[] {
... | class class_name[name] begin[{]
method[getGuidAsByteArray, return_type[type[byte]], modifier[public static], parameter[GUID]] begin[{]
local_variable[type[UUID], uuid]
local_variable[type[ByteBuffer], buff]
call[buff.putLong, parameter[call[uuid.getMostSignificantBits, parameter... | Keyword[public] Keyword[static] Keyword[byte] operator[SEP] operator[SEP] identifier[getGuidAsByteArray] operator[SEP] Keyword[final] identifier[String] identifier[GUID] operator[SEP] {
Keyword[final] identifier[UUID] identifier[uuid] operator[=] identifier[UUID] operator[SEP] identifier[fromString] operator[SEP... |
@BetaApi
public final Operation insertTargetHttpProxy(
String project, TargetHttpProxy targetHttpProxyResource) {
InsertTargetHttpProxyHttpRequest request =
InsertTargetHttpProxyHttpRequest.newBuilder()
.setProject(project)
.setTargetHttpProxyResource(targetHttpProxyResource... | class class_name[name] begin[{]
method[insertTargetHttpProxy, return_type[type[Operation]], modifier[final public], parameter[project, targetHttpProxyResource]] begin[{]
local_variable[type[InsertTargetHttpProxyHttpRequest], request]
return[call[.insertTargetHttpProxy, parameter[member[.request... | annotation[@] identifier[BetaApi] Keyword[public] Keyword[final] identifier[Operation] identifier[insertTargetHttpProxy] operator[SEP] identifier[String] identifier[project] , identifier[TargetHttpProxy] identifier[targetHttpProxyResource] operator[SEP] {
identifier[InsertTargetHttpProxyHttpRequest] identifier[... |
public final void mT__67() throws RecognitionException {
try {
int _type = T__67;
int _channel = DEFAULT_TOKEN_CHANNEL;
// InternalPureXbase.g:65:7: ( 'while' )
// InternalPureXbase.g:65:9: 'while'
{
match("while");
}
... | class class_name[name] begin[{]
method[mT__67, return_type[void], modifier[final public], parameter[]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MemberReference(member=T__67, postfix_operators=[], prefix_operators=[]... | Keyword[public] Keyword[final] Keyword[void] identifier[mT__67] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] {
Keyword[try] {
Keyword[int] identifier[_type] operator[=] identifier[T__67] operator[SEP] Keyword[int] identifier[_channel] operator[=] identifier[DEFAULT_TOKE... |
protected void count_and_yield(boolean moreExpected) throws SAXException
{
if(!moreExpected) eventcounter=0;
if(--eventcounter<=0)
{
co_yield(true);
eventcounter=frequency;
}
} | class class_name[name] begin[{]
method[count_and_yield, return_type[void], modifier[protected], parameter[moreExpected]] begin[{]
if[member[.moreExpected]] begin[{]
assign[member[.eventcounter], literal[0]]
else begin[{]
None
end[}]
if[binary_operatio... | Keyword[protected] Keyword[void] identifier[count_and_yield] operator[SEP] Keyword[boolean] identifier[moreExpected] operator[SEP] Keyword[throws] identifier[SAXException] {
Keyword[if] operator[SEP] operator[!] identifier[moreExpected] operator[SEP] identifier[eventcounter] operator[=] Other[0] operator[SEP] Ke... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.