code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public static IDLProxyObject createSingle(String data, boolean debug, boolean isUniName) {
return createSingle(data, debug, null, isUniName);
} | class class_name[name] begin[{]
method[createSingle, return_type[type[IDLProxyObject]], modifier[public static], parameter[data, debug, isUniName]] begin[{]
return[call[.createSingle, parameter[member[.data], member[.debug], literal[null], member[.isUniName]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[IDLProxyObject] identifier[createSingle] operator[SEP] identifier[String] identifier[data] , Keyword[boolean] identifier[debug] , Keyword[boolean] identifier[isUniName] operator[SEP] {
Keyword[return] identifier[createSingle] operator[SEP] identifier[data] , identifi... |
public List<DataPoint> getDataList() {
List<DataPoint> dataListCopy = new LinkedList<eu.hansolo.steelseries.tools.DataPoint>();
dataListCopy.addAll(DATA_LIST);
return dataListCopy;
} | class class_name[name] begin[{]
method[getDataList, return_type[type[List]], modifier[public], parameter[]] begin[{]
local_variable[type[List], dataListCopy]
call[dataListCopy.addAll, parameter[member[.DATA_LIST]]]
return[member[.dataListCopy]]
end[}]
END[}] | Keyword[public] identifier[List] operator[<] identifier[DataPoint] operator[>] identifier[getDataList] operator[SEP] operator[SEP] {
identifier[List] operator[<] identifier[DataPoint] operator[>] identifier[dataListCopy] operator[=] Keyword[new] identifier[LinkedList] operator[<] identifier[eu] operator[SEP] ide... |
@Inline(value="$2.$3copyOf($1)", imported=ImmutableList.class)
public static <T> List<T> immutableCopy(List<? extends T> list) {
return ImmutableList.copyOf(list);
} | class class_name[name] begin[{]
method[immutableCopy, return_type[type[List]], modifier[public static], parameter[list]] begin[{]
return[call[ImmutableList.copyOf, parameter[member[.list]]]]
end[}]
END[}] | annotation[@] identifier[Inline] operator[SEP] identifier[value] operator[=] literal[String] , identifier[imported] operator[=] identifier[ImmutableList] operator[SEP] Keyword[class] operator[SEP] Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[List] operator[<] identifier[T] operator[... |
public static <T> List<T> load(ClassLoader classLoader, Class<T> serviceType) {
List<T> foundServices = new ArrayList<>();
Iterator<T> iterator = ServiceLoader.load(serviceType, classLoader).iterator();
while (checkHasNextSafely(iterator)) {
try {
T item = iterator.n... | class class_name[name] begin[{]
method[load, return_type[type[List]], modifier[public static], parameter[classLoader, serviceType]] begin[{]
local_variable[type[List], foundServices]
local_variable[type[Iterator], iterator]
while[call[.checkHasNextSafely, parameter[member[.itera... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[List] operator[<] identifier[T] operator[>] identifier[load] operator[SEP] identifier[ClassLoader] identifier[classLoader] , identifier[Class] operator[<] identifier[T] operator[>] identifier[serviceType] operator[SEP] {
identifier... |
public Array readData(Variable v2, Section section)
throws IOException, InvalidRangeException {
return new ArraySequence(sm, new SeqIter(), nelems);
} | class class_name[name] begin[{]
method[readData, return_type[type[Array]], modifier[public], parameter[v2, section]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=sm, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), ClassCreator(arguments=[], body=None, constructor... | Keyword[public] identifier[Array] identifier[readData] operator[SEP] identifier[Variable] identifier[v2] , identifier[Section] identifier[section] operator[SEP] Keyword[throws] identifier[IOException] , identifier[InvalidRangeException] {
Keyword[return] Keyword[new] identifier[ArraySequence] operator[SEP] ide... |
@NullSafe
public static byte[] toByteArray(InputStream in) throws IOException {
Assert.notNull(in, "The InputStream to read bytes from cannot be null");
ByteArrayOutputStream out = new ByteArrayOutputStream(in.available());
byte[] buffer = new byte[DEFAULT_BUFFER_SIZE];
int bytesRead;
while (... | class class_name[name] begin[{]
method[toByteArray, return_type[type[byte]], modifier[public static], parameter[in]] begin[{]
call[Assert.notNull, parameter[member[.in], literal["The InputStream to read bytes from cannot be null"]]]
local_variable[type[ByteArrayOutputStream], out]
... | annotation[@] identifier[NullSafe] Keyword[public] Keyword[static] Keyword[byte] operator[SEP] operator[SEP] identifier[toByteArray] operator[SEP] identifier[InputStream] identifier[in] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[Assert] operator[SEP] identifier[notNull] operator[SEP] iden... |
public final BatchInsertMeta insertHStmnt() throws RecognitionException {
BatchInsertMeta bMeta = null;
Token id=null;
Token paths=null;
Token gran=null;
Token delim=null;
Token listDelim=null;
Token type=null;
Token size=null;
Token boundary=null;
List<Interval> i =null;
bMeta = new BatchInse... | class class_name[name] begin[{]
method[insertHStmnt, return_type[type[BatchInsertMeta]], modifier[final public], parameter[]] begin[{]
local_variable[type[BatchInsertMeta], bMeta]
local_variable[type[Token], id]
local_variable[type[Token], paths]
local_variable[type[Token], gran... | Keyword[public] Keyword[final] identifier[BatchInsertMeta] identifier[insertHStmnt] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] {
identifier[BatchInsertMeta] identifier[bMeta] operator[=] Other[null] operator[SEP] identifier[Token] identifier[id] operator[=] Other[null] operator[... |
public static String getFunctionBody( String function ) {
return RegexpUtils.getMatcher( FUNCTION_BODY_PATTERN, true ).getGroupIfMatches( function, 1 );
} | class class_name[name] begin[{]
method[getFunctionBody, return_type[type[String]], modifier[public static], parameter[function]] begin[{]
return[call[RegexpUtils.getMatcher, parameter[member[.FUNCTION_BODY_PATTERN], literal[true]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[String] identifier[getFunctionBody] operator[SEP] identifier[String] identifier[function] operator[SEP] {
Keyword[return] identifier[RegexpUtils] operator[SEP] identifier[getMatcher] operator[SEP] identifier[FUNCTION_BODY_PATTERN] , literal[boolean] operator[SEP] opera... |
public static Date addHour(Date date, int amount) {
return add(date, Calendar.HOUR, amount);
} | class class_name[name] begin[{]
method[addHour, return_type[type[Date]], modifier[public static], parameter[date, amount]] begin[{]
return[call[.add, parameter[member[.date], member[Calendar.HOUR], member[.amount]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[Date] identifier[addHour] operator[SEP] identifier[Date] identifier[date] , Keyword[int] identifier[amount] operator[SEP] {
Keyword[return] identifier[add] operator[SEP] identifier[date] , identifier[Calendar] operator[SEP] identifier[HOUR] , identifier[amount] opera... |
public float getProgress() throws IOException {
long subprogress = 0; // bytes processed in current split
if (null != curReader) {
// idx is always one past the current subsplit's true index.
subprogress = (long)(curReader.getProgress() * split.getLength(idx - 1));
}
return Math.min(1.0f,... | class class_name[name] begin[{]
method[getProgress, return_type[type[float]], modifier[public], parameter[]] begin[{]
local_variable[type[long], subprogress]
if[binary_operation[literal[null], !=, member[.curReader]]] begin[{]
assign[member[.subprogress], Cast(ex... | Keyword[public] Keyword[float] identifier[getProgress] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[long] identifier[subprogress] operator[=] Other[0] operator[SEP] Keyword[if] operator[SEP] Other[null] operator[!=] identifier[curReader] operator[SEP] {
identifier[subp... |
private void doWait(long loginTimeoutExpiration) throws SQLException {
try {
if (loginTimeoutExpiration > 0) {
long timeToWait = loginTimeoutExpiration
- System.currentTimeMillis();
if (timeToWait > 0) {
this.wai... | class class_name[name] begin[{]
method[doWait, return_type[void], modifier[private], parameter[loginTimeoutExpiration]] begin[{]
TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=loginTimeoutExpiration, postfix_operators=[], prefix_operators=[], qualifier=, selec... | Keyword[private] Keyword[void] identifier[doWait] operator[SEP] Keyword[long] identifier[loginTimeoutExpiration] operator[SEP] Keyword[throws] identifier[SQLException] {
Keyword[try] {
Keyword[if] operator[SEP] identifier[loginTimeoutExpiration] operator[>] Other[0] operator[SEP] {
Keyw... |
public static <T extends ImageGray<T>>
InputToBinary<T> localGaussian(ConfigLength regionWidth, double scale, boolean down, Class<T> inputType) {
if( BOverrideFactoryThresholdBinary.localGaussian != null )
return BOverrideFactoryThresholdBinary.localGaussian.handle(regionWidth, scale, down, inputType);
return n... | class class_name[name] begin[{]
method[localGaussian, return_type[type[InputToBinary]], modifier[public static], parameter[regionWidth, scale, down, inputType]] begin[{]
if[binary_operation[member[BOverrideFactoryThresholdBinary.localGaussian], !=, literal[null]]] begin[{]
return[call[BOverride... | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[ImageGray] operator[<] identifier[T] operator[>] operator[>] identifier[InputToBinary] operator[<] identifier[T] operator[>] identifier[localGaussian] operator[SEP] identifier[ConfigLength] identifier[regionWidth] , Keyword[double] i... |
public GeometricResult estimate(List<Homography2D_F64> viewsI_to_view0 ) {
calibration.reset();
int N = viewsI_to_view0.size();
if( !computeInverseH(viewsI_to_view0) )
return GeometricResult.SOLVE_FAILED;
fillInConstraintMatrix();
// Compute the SVD for its null space
if( !svd.decompose(A)) {
retur... | class class_name[name] begin[{]
method[estimate, return_type[type[GeometricResult]], modifier[public], parameter[viewsI_to_view0]] begin[{]
call[calibration.reset, parameter[]]
local_variable[type[int], N]
if[call[.computeInverseH, parameter[member[.viewsI_to_view0]]]] b... | Keyword[public] identifier[GeometricResult] identifier[estimate] operator[SEP] identifier[List] operator[<] identifier[Homography2D_F64] operator[>] identifier[viewsI_to_view0] operator[SEP] {
identifier[calibration] operator[SEP] identifier[reset] operator[SEP] operator[SEP] operator[SEP] Keyword[int] identifie... |
@Deprecated
public static Cookie cookie(String name, String value) {
return Cookies.cookie(name, value);
} | class class_name[name] begin[{]
method[cookie, return_type[type[Cookie]], modifier[public static], parameter[name, value]] begin[{]
return[call[Cookies.cookie, parameter[member[.name], member[.value]]]]
end[}]
END[}] | annotation[@] identifier[Deprecated] Keyword[public] Keyword[static] identifier[Cookie] identifier[cookie] operator[SEP] identifier[String] identifier[name] , identifier[String] identifier[value] operator[SEP] {
Keyword[return] identifier[Cookies] operator[SEP] identifier[cookie] operator[SEP] identifier[name] ... |
@Override
public Long scheduleRequest(String commandId, Date date, CommandContext ctx) {
if (ctx == null) {
throw new IllegalStateException("A Context Must Be Provided! ");
}
String businessKey = (String) ctx.getData("businessKey");
RequestInfo requestInfo = new RequestI... | class class_name[name] begin[{]
method[scheduleRequest, return_type[type[Long]], modifier[public], parameter[commandId, date, ctx]] begin[{]
if[binary_operation[member[.ctx], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[],... | annotation[@] identifier[Override] Keyword[public] identifier[Long] identifier[scheduleRequest] operator[SEP] identifier[String] identifier[commandId] , identifier[Date] identifier[date] , identifier[CommandContext] identifier[ctx] operator[SEP] {
Keyword[if] operator[SEP] identifier[ctx] operator[==] Other[nu... |
private boolean newGene(Gene previousGene, String newGeneId) {
return previousGene == null || !newGeneId.equals(previousGene.getId());
} | class class_name[name] begin[{]
method[newGene, return_type[type[boolean]], modifier[private], parameter[previousGene, newGeneId]] begin[{]
return[binary_operation[binary_operation[member[.previousGene], ==, literal[null]], ||, call[newGeneId.equals, parameter[call[previousGene.getId, parameter[]]]]]]
... | Keyword[private] Keyword[boolean] identifier[newGene] operator[SEP] identifier[Gene] identifier[previousGene] , identifier[String] identifier[newGeneId] operator[SEP] {
Keyword[return] identifier[previousGene] operator[==] Other[null] operator[||] operator[!] identifier[newGeneId] operator[SEP] identifier[equal... |
static JobDef map(ResultSet rs, int colShift)
{
JobDef tmp = new JobDef();
try
{
tmp.id = rs.getInt(1 + colShift);
tmp.application = rs.getString(2 + colShift);
tmp.applicationName = rs.getString(3 + colShift);
tmp.canBeRestarted = true;
... | class class_name[name] begin[{]
method[map, return_type[type[JobDef]], modifier[static], parameter[rs, colShift]] begin[{]
local_variable[type[JobDef], tmp]
TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(member=id, postfix_operators=[], prefix_operator... | Keyword[static] identifier[JobDef] identifier[map] operator[SEP] identifier[ResultSet] identifier[rs] , Keyword[int] identifier[colShift] operator[SEP] {
identifier[JobDef] identifier[tmp] operator[=] Keyword[new] identifier[JobDef] operator[SEP] operator[SEP] operator[SEP] Keyword[try] {
identifier[... |
@Deprecated
public ImageTask createImageTask(String url, int requestWidth, int requestHeight, ImageReuseInfo imageReuseInfo) {
ImageTask imageTask = ImageTask.obtain();
if (imageTask == null) {
imageTask = new ImageTask();
}
ImageLoadRequest imageLoadRequest = new ImageLo... | class class_name[name] begin[{]
method[createImageTask, return_type[type[ImageTask]], modifier[public], parameter[url, requestWidth, requestHeight, imageReuseInfo]] begin[{]
local_variable[type[ImageTask], imageTask]
if[binary_operation[member[.imageTask], ==, literal[null]]] begin[{]
... | annotation[@] identifier[Deprecated] Keyword[public] identifier[ImageTask] identifier[createImageTask] operator[SEP] identifier[String] identifier[url] , Keyword[int] identifier[requestWidth] , Keyword[int] identifier[requestHeight] , identifier[ImageReuseInfo] identifier[imageReuseInfo] operator[SEP] {
ident... |
@SuppressWarnings("squid:S1067")
protected boolean isSymbolCharacter(Char ch) {
if (ch.isEndOfInput() || ch.isDigit() || ch.isLetter() || ch.isWhitepace()) {
return false;
}
char c = ch.getValue();
if (Character.isISOControl(c)) {
return false;
}
... | class class_name[name] begin[{]
method[isSymbolCharacter, return_type[type[boolean]], modifier[protected], parameter[ch]] begin[{]
if[binary_operation[binary_operation[binary_operation[call[ch.isEndOfInput, parameter[]], ||, call[ch.isDigit, parameter[]]], ||, call[ch.isLetter, parameter[]]], |... | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[protected] Keyword[boolean] identifier[isSymbolCharacter] operator[SEP] identifier[Char] identifier[ch] operator[SEP] {
Keyword[if] operator[SEP] identifier[ch] operator[SEP] identifier[isEndOfInput] operator[SEP] oper... |
@Nonnull
public MapBasedXPathFunctionResolver loadXQuery (@Nonnull @WillClose final InputStream aXQueryIS) throws XPathException,
IOException
{
ValueEnforcer.notNull (aXQueryIS, "XQueryIS");
try
{
... | class class_name[name] begin[{]
method[loadXQuery, return_type[type[MapBasedXPathFunctionResolver]], modifier[public], parameter[aXQueryIS]] begin[{]
call[ValueEnforcer.notNull, parameter[member[.aXQueryIS], literal["XQueryIS"]]]
TryStatement(block=[LocalVariableDeclaration(annotations=... | annotation[@] identifier[Nonnull] Keyword[public] identifier[MapBasedXPathFunctionResolver] identifier[loadXQuery] operator[SEP] annotation[@] identifier[Nonnull] annotation[@] identifier[WillClose] Keyword[final] identifier[InputStream] identifier[aXQueryIS] operator[SEP] Keyword[throws] identifier[XPathException] , ... |
public static void safeClose(Channel channel, Closeable... fileChannels) throws IOException {
if (channel != null && channel.isOpen()) {
//关闭旧的下载连接
channel.close();
}
if (fileChannels != null && fileChannels.length > 0) {
for (Closeable closeable : fileChannels) {
if (closeable != ... | class class_name[name] begin[{]
method[safeClose, return_type[void], modifier[public static], parameter[channel, fileChannels]] begin[{]
if[binary_operation[binary_operation[member[.channel], !=, literal[null]], &&, call[channel.isOpen, parameter[]]]] begin[{]
call[chann... | Keyword[public] Keyword[static] Keyword[void] identifier[safeClose] operator[SEP] identifier[Channel] identifier[channel] , identifier[Closeable] operator[...] identifier[fileChannels] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[if] operator[SEP] identifier[channel] operator[!=] Other[null] ... |
public static List<File> resolveRecursively(final List<File> files,
final List<Filter<File>> exclusionFilters,
final Log log) {
// Check sanity
Validate.notNull(files, "files");
final List<Filter<Fi... | class class_name[name] begin[{]
method[resolveRecursively, return_type[type[List]], modifier[public static], parameter[files, exclusionFilters, log]] begin[{]
call[Validate.notNull, parameter[member[.files], literal["files"]]]
local_variable[type[List], effectiveExclusions]
loca... | Keyword[public] Keyword[static] identifier[List] operator[<] identifier[File] operator[>] identifier[resolveRecursively] operator[SEP] Keyword[final] identifier[List] operator[<] identifier[File] operator[>] identifier[files] , Keyword[final] identifier[List] operator[<] identifier[Filter] operator[<] identifier[File]... |
private String escape(final String val) {
// TODO: this function is ugly, pass this work off to SQLite, then we
// don't have to worry about Unicode 4, other characters needing
// escaping, etc.
int len = val.length();
StringBuilder buf = new StringBuilder(len);
for (int i = 0; i < len; i++) {
... | class class_name[name] begin[{]
method[escape, return_type[type[String]], modifier[private], parameter[val]] begin[{]
local_variable[type[int], len]
local_variable[type[StringBuilder], buf]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(op... | Keyword[private] identifier[String] identifier[escape] operator[SEP] Keyword[final] identifier[String] identifier[val] operator[SEP] {
Keyword[int] identifier[len] operator[=] identifier[val] operator[SEP] identifier[length] operator[SEP] operator[SEP] operator[SEP] identifier[StringBuilder] identifier[buf] oper... |
public DevPipeBlob getDevPipeBlobObject() {
DevPipeDataElt[] elementList = new DevPipeDataElt[size()];
for (int i=0 ; i<size() ; i++)
elementList[i] = get(i).getDevPipeDataEltObject();
return new DevPipeBlob(name, elementList);
} | class class_name[name] begin[{]
method[getDevPipeBlobObject, return_type[type[DevPipeBlob]], modifier[public], parameter[]] begin[{]
local_variable[type[DevPipeDataElt], elementList]
ForStatement(body=StatementExpression(expression=Assignment(expressionl=MemberReference(member=elementList, post... | Keyword[public] identifier[DevPipeBlob] identifier[getDevPipeBlobObject] operator[SEP] operator[SEP] {
identifier[DevPipeDataElt] operator[SEP] operator[SEP] identifier[elementList] operator[=] Keyword[new] identifier[DevPipeDataElt] operator[SEP] identifier[size] operator[SEP] operator[SEP] operator[SEP] operat... |
public static <T extends Number> WithinGroup<T> percentileDisc(Expression<T> arg) {
return new WithinGroup<T>(arg.getType(), SQLOps.PERCENTILEDISC, arg);
} | class class_name[name] begin[{]
method[percentileDisc, return_type[type[WithinGroup]], modifier[public static], parameter[arg]] begin[{]
return[ClassCreator(arguments=[MethodInvocation(arguments=[], member=getType, postfix_operators=[], prefix_operators=[], qualifier=arg, selectors=[], type_arguments=N... | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[Number] operator[>] identifier[WithinGroup] operator[<] identifier[T] operator[>] identifier[percentileDisc] operator[SEP] identifier[Expression] operator[<] identifier[T] operator[>] identifier[arg] operator[SEP] {
Keyword[ret... |
@NullSafe
public static String getClassSimpleName(Object obj) {
return obj != null ? obj.getClass().getSimpleName() : null;
} | class class_name[name] begin[{]
method[getClassSimpleName, return_type[type[String]], modifier[public static], parameter[obj]] begin[{]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=obj, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), operandr=... | annotation[@] identifier[NullSafe] Keyword[public] Keyword[static] identifier[String] identifier[getClassSimpleName] operator[SEP] identifier[Object] identifier[obj] operator[SEP] {
Keyword[return] identifier[obj] operator[!=] Other[null] operator[?] identifier[obj] operator[SEP] identifier[getClass] operator[SE... |
public Observable<OperationStatus> deleteExplicitListItemAsync(UUID appId, String versionId, UUID entityId, long itemId) {
return deleteExplicitListItemWithServiceResponseAsync(appId, versionId, entityId, itemId).map(new Func1<ServiceResponse<OperationStatus>, OperationStatus>() {
@Override
... | class class_name[name] begin[{]
method[deleteExplicitListItemAsync, return_type[type[Observable]], modifier[public], parameter[appId, versionId, entityId, itemId]] begin[{]
return[call[.deleteExplicitListItemWithServiceResponseAsync, parameter[member[.appId], member[.versionId], member[.entityId], memb... | Keyword[public] identifier[Observable] operator[<] identifier[OperationStatus] operator[>] identifier[deleteExplicitListItemAsync] operator[SEP] identifier[UUID] identifier[appId] , identifier[String] identifier[versionId] , identifier[UUID] identifier[entityId] , Keyword[long] identifier[itemId] operator[SEP] {
... |
public Resources analyze(Set<Path> projectClassPaths, Set<Path> projectSourcePaths, Set<String> ignoredResources) {
lock.lock();
try {
projectClassPaths.forEach(this::addProjectPath);
// analyze relevant classes
final JobRegistry jobRegistry = JobRegistry.getInstance... | class class_name[name] begin[{]
method[analyze, return_type[type[Resources]], modifier[public], parameter[projectClassPaths, projectSourcePaths, ignoredResources]] begin[{]
call[lock.lock, parameter[]]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[Method... | Keyword[public] identifier[Resources] identifier[analyze] operator[SEP] identifier[Set] operator[<] identifier[Path] operator[>] identifier[projectClassPaths] , identifier[Set] operator[<] identifier[Path] operator[>] identifier[projectSourcePaths] , identifier[Set] operator[<] identifier[String] operator[>] identifi... |
public static short pixel2WidthUnits(final int pxs) {
short widthUnits = (short) (EXCEL_COLUMN_WIDTH_FACTOR
* (pxs / UNIT_OFFSET_LENGTH));
widthUnits += UNIT_OFFSET_MAP[pxs % UNIT_OFFSET_LENGTH];
return widthUnits;
} | class class_name[name] begin[{]
method[pixel2WidthUnits, return_type[type[short]], modifier[public static], parameter[pxs]] begin[{]
local_variable[type[short], widthUnits]
assign[member[.widthUnits], member[.UNIT_OFFSET_MAP]]
return[member[.widthUnits]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[short] identifier[pixel2WidthUnits] operator[SEP] Keyword[final] Keyword[int] identifier[pxs] operator[SEP] {
Keyword[short] identifier[widthUnits] operator[=] operator[SEP] Keyword[short] operator[SEP] operator[SEP] identifier[EXCEL_COLUMN_WIDTH_FACTOR] operator[*] operat... |
public static <T1, T2, T3, T4, T5, T6, R> Function<Tuple6<T1, T2, T3, T4, T5, T6>, R> function(Function6<T1, T2, T3, T4, T5, T6, R> function) {
return tuple -> function.apply(tuple.getT1(), tuple.getT2(), tuple.getT3(), tuple.getT4(), tuple.getT5(), tuple.getT6());
} | class class_name[name] begin[{]
method[function, return_type[type[Function]], modifier[public static], parameter[function]] begin[{]
return[LambdaExpression(body=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=getT1, postfix_operators=[], prefix_operators=[], qualifier=tuple, selector... | Keyword[public] Keyword[static] operator[<] identifier[T1] , identifier[T2] , identifier[T3] , identifier[T4] , identifier[T5] , identifier[T6] , identifier[R] operator[>] identifier[Function] operator[<] identifier[Tuple6] operator[<] identifier[T1] , identifier[T2] , identifier[T3] , identifier[T4] , identi... |
private void addLicenses(MavenPomDescriptor pomDescriptor, Model model, Store store) {
List<License> licenses = model.getLicenses();
for (License license : licenses) {
MavenLicenseDescriptor licenseDescriptor = store.create(MavenLicenseDescriptor.class);
licenseDescriptor.setUrl(... | class class_name[name] begin[{]
method[addLicenses, return_type[void], modifier[private], parameter[pomDescriptor, model, store]] begin[{]
local_variable[type[List], licenses]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[Variable... | Keyword[private] Keyword[void] identifier[addLicenses] operator[SEP] identifier[MavenPomDescriptor] identifier[pomDescriptor] , identifier[Model] identifier[model] , identifier[Store] identifier[store] operator[SEP] {
identifier[List] operator[<] identifier[License] operator[>] identifier[licenses] operator[=]... |
private String getSelectClauseFragment(SignatureVariable var,
Term term,
Optional<TermType> termType,
AliasIndex index) {
/*
* Datatype for the main column (to which it is cast).
* Beware, it may defer the RDF datatype (the one of the type column).
*
* Why? Because m... | class class_name[name] begin[{]
method[getSelectClauseFragment, return_type[type[String]], modifier[private], parameter[var, term, termType, index]] begin[{]
local_variable[type[String], typeColumn]
local_variable[type[String], langColumn]
local_variable[type[String], mainColumn]
... | Keyword[private] identifier[String] identifier[getSelectClauseFragment] operator[SEP] identifier[SignatureVariable] identifier[var] , identifier[Term] identifier[term] , identifier[Optional] operator[<] identifier[TermType] operator[>] identifier[termType] , identifier[AliasIndex] identifier[index] operator[SEP] {
... |
@Override
public void dropSchema()
{
if (operation != null && operation.equalsIgnoreCase("create-drop"))
{
drop();
}
operation = null;
admin = null;
} | class class_name[name] begin[{]
method[dropSchema, return_type[void], modifier[public], parameter[]] begin[{]
if[binary_operation[binary_operation[member[.operation], !=, literal[null]], &&, call[operation.equalsIgnoreCase, parameter[literal["create-drop"]]]]] begin[{]
c... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[dropSchema] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[operation] operator[!=] Other[null] operator[&&] identifier[operation] operator[SEP] identifier[equalsIgnoreCase] operator[SEP] literal[String] operator[SEP] ... |
public Single<ByteBuf> getSeqnos() {
return Single.create(new Single.OnSubscribe<ByteBuf>() {
@Override
public void call(final SingleSubscriber<? super ByteBuf> subscriber) {
if (state() != LifecycleState.CONNECTED) {
subscriber.onError(new NotConnectedException());
return;
... | class class_name[name] begin[{]
method[getSeqnos, return_type[type[Single]], modifier[public], parameter[]] begin[{]
return[call[Single.create, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[IfStatement(condition=BinaryOperation... | Keyword[public] identifier[Single] operator[<] identifier[ByteBuf] operator[>] identifier[getSeqnos] operator[SEP] operator[SEP] {
Keyword[return] identifier[Single] operator[SEP] identifier[create] operator[SEP] Keyword[new] identifier[Single] operator[SEP] identifier[OnSubscribe] operator[<] identifier[ByteBuf... |
private void checkJsDocInBlockComments(String fileName) {
if (!compiler.getOptions().preservesDetailedSourceInfo()) {
// Comments only available if preservesDetailedSourceInfo is true.
return;
}
for (Comment comment : compiler.getComments(fileName)) {
if (comment.type == Comment.Type.BLOC... | class class_name[name] begin[{]
method[checkJsDocInBlockComments, return_type[void], modifier[private], parameter[fileName]] begin[{]
if[call[compiler.getOptions, parameter[]]] begin[{]
return[None]
else begin[{]
None
end[}]
ForStatement(body=BlockStatement(l... | Keyword[private] Keyword[void] identifier[checkJsDocInBlockComments] operator[SEP] identifier[String] identifier[fileName] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[compiler] operator[SEP] identifier[getOptions] operator[SEP] operator[SEP] operator[SEP] identifier[preservesDetailedSourceIn... |
public void add(int index, int element)
{
if (index == size())//special case, just appending
{
add(element);
}
else
{
boundsCheck(index);
enlargeIfNeeded(1);
System.arraycopy(array, index, array, index+1, end-index);
... | class class_name[name] begin[{]
method[add, return_type[void], modifier[public], parameter[index, element]] begin[{]
if[binary_operation[member[.index], ==, call[.size, parameter[]]]] begin[{]
call[.add, parameter[member[.element]]]
else begin[{]
... | Keyword[public] Keyword[void] identifier[add] operator[SEP] Keyword[int] identifier[index] , Keyword[int] identifier[element] operator[SEP] {
Keyword[if] operator[SEP] identifier[index] operator[==] identifier[size] operator[SEP] operator[SEP] operator[SEP] {
identifier[add] operator[SEP] identifier[... |
public List<RTMovie> getTopRentals(String country, int limit) throws RottenTomatoesException {
properties.clear();
properties.put(ApiBuilder.PROPERTY_URL, URL_TOP_RENTALS);
properties.put(ApiBuilder.PROPERTY_LIMIT, ApiBuilder.validateLimit(limit));
properties.put(ApiBuilder.PROPERTY_COUN... | class class_name[name] begin[{]
method[getTopRentals, return_type[type[List]], modifier[public], parameter[country, limit]] begin[{]
call[properties.clear, parameter[]]
call[properties.put, parameter[member[ApiBuilder.PROPERTY_URL], member[.URL_TOP_RENTALS]]]
cal... | Keyword[public] identifier[List] operator[<] identifier[RTMovie] operator[>] identifier[getTopRentals] operator[SEP] identifier[String] identifier[country] , Keyword[int] identifier[limit] operator[SEP] Keyword[throws] identifier[RottenTomatoesException] {
identifier[properties] operator[SEP] identifier[clear] ... |
public static Function<Object,Character> methodForCharacter(final String methodName, final Object... optionalParameters) {
return new Call<Object,Character>(Types.CHARACTER, methodName, VarArgsUtil.asOptionalObjectArray(Object.class,optionalParameters));
} | class class_name[name] begin[{]
method[methodForCharacter, return_type[type[Function]], modifier[public static], parameter[methodName, optionalParameters]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=CHARACTER, postfix_operators=[], prefix_operators=[], qualifier=Types, selectors=[])... | Keyword[public] Keyword[static] identifier[Function] operator[<] identifier[Object] , identifier[Character] operator[>] identifier[methodForCharacter] operator[SEP] Keyword[final] identifier[String] identifier[methodName] , Keyword[final] identifier[Object] operator[...] identifier[optionalParameters] operator[SEP] ... |
@Override
public void receiveUpdate(INDArray array) {
extCounter.getAndIncrement();
updatesLock.writeLock().lock();
if (updates == null) {
try (MemoryWorkspace workspace = Nd4j.getMemoryManager().scopeOutOfWorkspaces()) {
// TODO: this one has to be HOST-only if... | class class_name[name] begin[{]
method[receiveUpdate, return_type[void], modifier[public], parameter[array]] begin[{]
call[extCounter.getAndIncrement, parameter[]]
call[updatesLock.writeLock, parameter[]]
if[binary_operation[member[.updates], ==, literal[null]]] ... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[receiveUpdate] operator[SEP] identifier[INDArray] identifier[array] operator[SEP] {
identifier[extCounter] operator[SEP] identifier[getAndIncrement] operator[SEP] operator[SEP] operator[SEP] identifier[updatesLock] operator[SEP] identifi... |
public void setOptAbbrev(boolean optAbbrev) {
if (optVerbose) {
if (optAbbrev && optNoAbbrev) {
throw new IllegalArgumentException(ExceptionMessageMap.getMessage("000120")
+ " --abbrev cannot be used with --no-abbrev.");
}
this.optAbbrev = optAbbrev;
}
} | class class_name[name] begin[{]
method[setOptAbbrev, return_type[void], modifier[public], parameter[optAbbrev]] begin[{]
if[member[.optVerbose]] begin[{]
if[binary_operation[member[.optAbbrev], &&, member[.optNoAbbrev]]] begin[{]
ThrowStatement(expression... | Keyword[public] Keyword[void] identifier[setOptAbbrev] operator[SEP] Keyword[boolean] identifier[optAbbrev] operator[SEP] {
Keyword[if] operator[SEP] identifier[optVerbose] operator[SEP] {
Keyword[if] operator[SEP] identifier[optAbbrev] operator[&&] identifier[optNoAbbrev] operator[SEP] {
... |
@Deprecated
public List<Icon> getIconFiles() throws IOException {
List<IconPath> iconPaths = getIconPaths();
List<Icon> icons = new ArrayList<>(iconPaths.size());
for (IconPath iconPath : iconPaths) {
Icon icon = newFileIcon(iconPath.getPath(), iconPath.getDensity());
... | class class_name[name] begin[{]
method[getIconFiles, return_type[type[List]], modifier[public], parameter[]] begin[{]
local_variable[type[List], iconPaths]
local_variable[type[List], icons]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[],... | annotation[@] identifier[Deprecated] Keyword[public] identifier[List] operator[<] identifier[Icon] operator[>] identifier[getIconFiles] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[List] operator[<] identifier[IconPath] operator[>] identifier[iconPaths] operator[=] identifier[... |
public static boolean addHandle(VirtualFile owner, Closeable handle) {
RegistryEntry entry = getEntry(owner);
return entry.handles.add(handle);
} | class class_name[name] begin[{]
method[addHandle, return_type[type[boolean]], modifier[public static], parameter[owner, handle]] begin[{]
local_variable[type[RegistryEntry], entry]
return[call[entry.handles.add, parameter[member[.handle]]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[boolean] identifier[addHandle] operator[SEP] identifier[VirtualFile] identifier[owner] , identifier[Closeable] identifier[handle] operator[SEP] {
identifier[RegistryEntry] identifier[entry] operator[=] identifier[getEntry] operator[SEP] identifier[owner] operator[SEP] ope... |
public void setImportTablesNotStarted(java.util.Collection<String> importTablesNotStarted) {
if (importTablesNotStarted == null) {
this.importTablesNotStarted = null;
return;
}
this.importTablesNotStarted = new com.amazonaws.internal.SdkInternalList<String>(importTablesN... | class class_name[name] begin[{]
method[setImportTablesNotStarted, return_type[void], modifier[public], parameter[importTablesNotStarted]] begin[{]
if[binary_operation[member[.importTablesNotStarted], ==, literal[null]]] begin[{]
assign[THIS[member[None.importTablesNotSta... | Keyword[public] Keyword[void] identifier[setImportTablesNotStarted] operator[SEP] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[Collection] operator[<] identifier[String] operator[>] identifier[importTablesNotStarted] operator[SEP] {
Keyword[if] operator[SEP] identifier[importTablesNot... |
public static List<CommerceOrder> findByG_C(long groupId,
long commerceAccountId, int start, int end) {
return getPersistence().findByG_C(groupId, commerceAccountId, start, end);
} | class class_name[name] begin[{]
method[findByG_C, return_type[type[List]], modifier[public static], parameter[groupId, commerceAccountId, start, end]] begin[{]
return[call[.getPersistence, parameter[]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[List] operator[<] identifier[CommerceOrder] operator[>] identifier[findByG_C] operator[SEP] Keyword[long] identifier[groupId] , Keyword[long] identifier[commerceAccountId] , Keyword[int] identifier[start] , Keyword[int] identifier[end] operator[SEP] {
Keyword[return]... |
@Override
public boolean performFinish() {
/*
* Create a new location or get an existing one
*/
HadoopServer location = null;
if (mainPage.createNew.getSelection()) {
location = createNewPage.performFinish();
} else if (mainPage.table.getSelection().length == 1) {
location = (H... | class class_name[name] begin[{]
method[performFinish, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
local_variable[type[HadoopServer], location]
if[call[mainPage.createNew.getSelection, parameter[]]] begin[{]
assign[member[.location], call[c... | annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[performFinish] operator[SEP] operator[SEP] {
identifier[HadoopServer] identifier[location] operator[=] Other[null] operator[SEP] Keyword[if] operator[SEP] identifier[mainPage] operator[SEP] identifier[createNew] operator[SEP] identifi... |
public int getColunmIndexByName(final String colName) {
for (final JKTableColumn col : this.tableColumns) {
if (col.getName().equalsIgnoreCase(colName)) {
return col.getVisibleIndex();
}
}
return -1;
} | class class_name[name] begin[{]
method[getColunmIndexByName, return_type[type[int]], modifier[public], parameter[colName]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[], member=getName, postfix_operators=[], prefix_operators=[], qu... | Keyword[public] Keyword[int] identifier[getColunmIndexByName] operator[SEP] Keyword[final] identifier[String] identifier[colName] operator[SEP] {
Keyword[for] operator[SEP] Keyword[final] identifier[JKTableColumn] identifier[col] operator[:] Keyword[this] operator[SEP] identifier[tableColumns] operator[SEP] {
... |
public Map<String, String> extractNamedGroups(final CharSequence rawData) {
Matcher matcher = compiledPattern.matcher(rawData);
if (matcher.find()) {
MatchResult r = matcher.toMatchResult();
if (r != null && r.namedGroups() != null) {
return r.namedGroups();
}
}
return null;
... | class class_name[name] begin[{]
method[extractNamedGroups, return_type[type[Map]], modifier[public], parameter[rawData]] begin[{]
local_variable[type[Matcher], matcher]
if[call[matcher.find, parameter[]]] begin[{]
local_variable[type[MatchResult], r]
... | Keyword[public] identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[extractNamedGroups] operator[SEP] Keyword[final] identifier[CharSequence] identifier[rawData] operator[SEP] {
identifier[Matcher] identifier[matcher] operator[=] identifier[compiledPattern] operator[SEP] i... |
private void handleRange(final String range) {
final String[] parts = range.split("[\\-]+");
switch (parts.length) {
case 1:
// no range
final Integer singleNumber = toInt(parts[0]);
if (singleNumber != null) {
ranges.add(new Range(singleNumber, singleNumber));
}
break;
case 2:
... | class class_name[name] begin[{]
method[handleRange, return_type[void], modifier[private], parameter[range]] begin[{]
local_variable[type[String], parts]
SwitchStatement(cases=[SwitchStatementCase(case=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value=1)], s... | Keyword[private] Keyword[void] identifier[handleRange] operator[SEP] Keyword[final] identifier[String] identifier[range] operator[SEP] {
Keyword[final] identifier[String] operator[SEP] operator[SEP] identifier[parts] operator[=] identifier[range] operator[SEP] identifier[split] operator[SEP] literal[String] oper... |
public static String getVendorPropertyName(String prop) {
// we prefer vendor specific names by default
String vendorProp = JsUtils.camelize("-" + prefix + "-" + prop);
if (JsUtils.hasProperty(divStyle, vendorProp)) {
return vendorProp;
}
if (JsUtils.hasProperty(divStyle, prop)) {
retur... | class class_name[name] begin[{]
method[getVendorPropertyName, return_type[type[String]], modifier[public static], parameter[prop]] begin[{]
local_variable[type[String], vendorProp]
if[call[JsUtils.hasProperty, parameter[member[.divStyle], member[.vendorProp]]]] begin[{]
retu... | Keyword[public] Keyword[static] identifier[String] identifier[getVendorPropertyName] operator[SEP] identifier[String] identifier[prop] operator[SEP] {
identifier[String] identifier[vendorProp] operator[=] identifier[JsUtils] operator[SEP] identifier[camelize] operator[SEP] literal[String] operator[+] identifier[... |
public void standaloneLogon (BootstrapData data, DObjectManager omgr)
{
if (!_standalone) {
throw new IllegalStateException("Must call prepareStandaloneLogon() first.");
}
gotBootstrap(data, omgr);
} | class class_name[name] begin[{]
method[standaloneLogon, return_type[void], modifier[public], parameter[data, omgr]] begin[{]
if[member[._standalone]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selecto... | Keyword[public] Keyword[void] identifier[standaloneLogon] operator[SEP] identifier[BootstrapData] identifier[data] , identifier[DObjectManager] identifier[omgr] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[_standalone] operator[SEP] {
Keyword[throw] Keyword[new] identifier[Illegal... |
public ServiceFuture<String> generateUriAsync(String resourceGroupName, String automationAccountName, final ServiceCallback<String> serviceCallback) {
return ServiceFuture.fromResponse(generateUriWithServiceResponseAsync(resourceGroupName, automationAccountName), serviceCallback);
} | class class_name[name] begin[{]
method[generateUriAsync, return_type[type[ServiceFuture]], modifier[public], parameter[resourceGroupName, automationAccountName, serviceCallback]] begin[{]
return[call[ServiceFuture.fromResponse, parameter[call[.generateUriWithServiceResponseAsync, parameter[member[.reso... | Keyword[public] identifier[ServiceFuture] operator[<] identifier[String] operator[>] identifier[generateUriAsync] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[automationAccountName] , Keyword[final] identifier[ServiceCallback] operator[<] identifier[String] operator[>... |
public static @NotNull String format(@NotNull String format, @NotNull Object... args) {
Object[] argsAsText = new String[args.length];
for (int i = 0; i < args.length; i++) {
argsAsText[i] = toStringOf(args[i]);
}
return String.format(format, argsAsText);
} | class class_name[name] begin[{]
method[format, return_type[type[String]], modifier[public static], parameter[format, args]] begin[{]
local_variable[type[Object], argsAsText]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=Assignment(expressionl=MemberRefe... | Keyword[public] Keyword[static] annotation[@] identifier[NotNull] identifier[String] identifier[format] operator[SEP] annotation[@] identifier[NotNull] identifier[String] identifier[format] , annotation[@] identifier[NotNull] identifier[Object] operator[...] identifier[args] operator[SEP] {
identifier[Object] o... |
@Override
public void write(byte[] bytes, int off, int len) throws IOException {
super.write(bytes, off, len);
dataLength += len;
} | class class_name[name] begin[{]
method[write, return_type[void], modifier[public], parameter[bytes, off, len]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=bytes, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(member=off, postfix_operat... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[write] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[bytes] , Keyword[int] identifier[off] , Keyword[int] identifier[len] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[super] operator[SEP] identif... |
private Object tryConvert(
final MfClientHttpRequestFactory clientHttpRequestFactory,
final Object rowValue) throws URISyntaxException, IOException {
if (this.converters.isEmpty()) {
return rowValue;
}
String value = String.valueOf(rowValue);
for (Tab... | class class_name[name] begin[{]
method[tryConvert, return_type[type[Object]], modifier[private], parameter[clientHttpRequestFactory, rowValue]] begin[{]
if[THIS[member[None.converters]call[None.isEmpty, parameter[]]]] begin[{]
return[member[.rowValue]]
else begin[{]
None
... | Keyword[private] identifier[Object] identifier[tryConvert] operator[SEP] Keyword[final] identifier[MfClientHttpRequestFactory] identifier[clientHttpRequestFactory] , Keyword[final] identifier[Object] identifier[rowValue] operator[SEP] Keyword[throws] identifier[URISyntaxException] , identifier[IOException] {
K... |
public List<HistoryEvent> createUserOperationLogEvents(UserOperationLogContext context) {
List<HistoryEvent> historyEvents = new ArrayList<HistoryEvent>();
String operationId = Context.getCommandContext().getOperationId();
context.setOperationId(operationId);
for (UserOperationLogContextEntry entry : ... | class class_name[name] begin[{]
method[createUserOperationLogEvents, return_type[type[List]], modifier[public], parameter[context]] begin[{]
local_variable[type[List], historyEvents]
local_variable[type[String], operationId]
call[context.setOperationId, parameter[member[.operati... | Keyword[public] identifier[List] operator[<] identifier[HistoryEvent] operator[>] identifier[createUserOperationLogEvents] operator[SEP] identifier[UserOperationLogContext] identifier[context] operator[SEP] {
identifier[List] operator[<] identifier[HistoryEvent] operator[>] identifier[historyEvents] operator[=] ... |
public SessionEntities getSessions() {
SessionEntities sessionEntities = restClient.get("sessions", SessionEntities.class,
new HashMap<String, String>());
return sessionEntities;
} | class class_name[name] begin[{]
method[getSessions, return_type[type[SessionEntities]], modifier[public], parameter[]] begin[{]
local_variable[type[SessionEntities], sessionEntities]
return[member[.sessionEntities]]
end[}]
END[}] | Keyword[public] identifier[SessionEntities] identifier[getSessions] operator[SEP] operator[SEP] {
identifier[SessionEntities] identifier[sessionEntities] operator[=] identifier[restClient] operator[SEP] identifier[get] operator[SEP] literal[String] , identifier[SessionEntities] operator[SEP] Keyword[class] , K... |
public void removeZero() {
boolean freeze = false;
if (feature.isStopIncrement()) {
feature.setStopIncrement(false);
freeze = true;
}
TIntObjectHashMap<String> index = (TIntObjectHashMap<String>) feature.toInverseIndexMap();
System.out.println("原字典大小"+index.size());
System.out.println("原字典... | class class_name[name] begin[{]
method[removeZero, return_type[void], modifier[public], parameter[]] begin[{]
local_variable[type[boolean], freeze]
if[call[feature.isStopIncrement, parameter[]]] begin[{]
call[feature.setStopIncrement, parameter[literal[false]]]
... | Keyword[public] Keyword[void] identifier[removeZero] operator[SEP] operator[SEP] {
Keyword[boolean] identifier[freeze] operator[=] literal[boolean] operator[SEP] Keyword[if] operator[SEP] identifier[feature] operator[SEP] identifier[isStopIncrement] operator[SEP] operator[SEP] operator[SEP] {
identifi... |
@SuppressWarnings("unchecked")
@Override
public V remove(Object key) {
LinkedHashMapSegment<K, V> seg = segmentFor(key.hashCode());
try {
seg.lock.lock();
return mapEventListener.onRemoveEntry((K) key, seg.remove(key));
} finally {
seg.lock.unlock();
... | class class_name[name] begin[{]
method[remove, return_type[type[V]], modifier[public], parameter[key]] begin[{]
local_variable[type[LinkedHashMapSegment], seg]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[], member=lock, postfix_operators=[], prefix_operators=[... | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] annotation[@] identifier[Override] Keyword[public] identifier[V] identifier[remove] operator[SEP] identifier[Object] identifier[key] operator[SEP] {
identifier[LinkedHashMapSegment] operator[<] identifier[K] , identifier[V] o... |
public LoggingFraction rootLogger(Level level, String... handlers) {
rootLogger(new RootLogger().level(level)
.handlers(handlers));
return this;
} | class class_name[name] begin[{]
method[rootLogger, return_type[type[LoggingFraction]], modifier[public], parameter[level, handlers]] begin[{]
call[.rootLogger, parameter[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=N... | Keyword[public] identifier[LoggingFraction] identifier[rootLogger] operator[SEP] identifier[Level] identifier[level] , identifier[String] operator[...] identifier[handlers] operator[SEP] {
identifier[rootLogger] operator[SEP] Keyword[new] identifier[RootLogger] operator[SEP] operator[SEP] operator[SEP] identifi... |
public static <T extends Comparable<? super T>> void insertionSort( T[] arr )
{
int j;
for ( int i = 1; i < arr.length; i++ ) {
T tmp = arr[i];
for ( j = i; j > 0 && tmp.compareTo(arr[j-1]) < 0; j--) {
arr[j] = arr[j-1];
}
... | class class_name[name] begin[{]
method[insertionSort, return_type[void], modifier[public static], parameter[arr]] begin[{]
local_variable[type[int], j]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[]... | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[Comparable] operator[<] operator[?] Keyword[super] identifier[T] operator[>] operator[>] Keyword[void] identifier[insertionSort] operator[SEP] identifier[T] operator[SEP] operator[SEP] identifier[arr] operator[SEP] {
Keyword[in... |
@PublicEvolving
public void setFloat(ConfigOption<Float> key, float value) {
setValueInternal(key.key(), value);
} | class class_name[name] begin[{]
method[setFloat, return_type[void], modifier[public], parameter[key, value]] begin[{]
call[.setValueInternal, parameter[call[key.key, parameter[]], member[.value]]]
end[}]
END[}] | annotation[@] identifier[PublicEvolving] Keyword[public] Keyword[void] identifier[setFloat] operator[SEP] identifier[ConfigOption] operator[<] identifier[Float] operator[>] identifier[key] , Keyword[float] identifier[value] operator[SEP] {
identifier[setValueInternal] operator[SEP] identifier[key] operator[SEP]... |
public Clustering<Model> run(Relation<V> rel) {
fulldatabase = preprocess(rel);
processedIDs = DBIDUtil.newHashSet(fulldatabase.size());
noiseDim = dimensionality(fulldatabase);
FiniteProgress progress = LOG.isVerbose() ? new FiniteProgress("CASH Clustering", fulldatabase.size(), LOG) : null;
Clust... | class class_name[name] begin[{]
method[run, return_type[type[Clustering]], modifier[public], parameter[rel]] begin[{]
assign[member[.fulldatabase], call[.preprocess, parameter[member[.rel]]]]
assign[member[.processedIDs], call[DBIDUtil.newHashSet, parameter[call[fulldatabase.siz... | Keyword[public] identifier[Clustering] operator[<] identifier[Model] operator[>] identifier[run] operator[SEP] identifier[Relation] operator[<] identifier[V] operator[>] identifier[rel] operator[SEP] {
identifier[fulldatabase] operator[=] identifier[preprocess] operator[SEP] identifier[rel] operator[SEP] operato... |
public Trigger<? super S> getUpdateTrigger() {
ForUpdate<S> forUpdate = mForUpdate;
return forUpdate.isEmpty() ? null : forUpdate;
} | class class_name[name] begin[{]
method[getUpdateTrigger, return_type[type[Trigger]], modifier[public], parameter[]] begin[{]
local_variable[type[ForUpdate], forUpdate]
return[TernaryExpression(condition=MethodInvocation(arguments=[], member=isEmpty, postfix_operators=[], prefix_operators=[], qu... | Keyword[public] identifier[Trigger] operator[<] operator[?] Keyword[super] identifier[S] operator[>] identifier[getUpdateTrigger] operator[SEP] operator[SEP] {
identifier[ForUpdate] operator[<] identifier[S] operator[>] identifier[forUpdate] operator[=] identifier[mForUpdate] operator[SEP] Keyword[return] identi... |
public final int getInt8(final int pos) {
if (pos >= limit || pos < 0) throw new IllegalArgumentException("limit excceed: " + pos);
return buffer[origin + pos];
} | class class_name[name] begin[{]
method[getInt8, return_type[type[int]], modifier[final public], parameter[pos]] begin[{]
if[binary_operation[binary_operation[member[.pos], >=, member[.limit]], ||, binary_operation[member[.pos], <, literal[0]]]] begin[{]
ThrowStatement(expression=ClassCreator(ar... | Keyword[public] Keyword[final] Keyword[int] identifier[getInt8] operator[SEP] Keyword[final] Keyword[int] identifier[pos] operator[SEP] {
Keyword[if] operator[SEP] identifier[pos] operator[>=] identifier[limit] operator[||] identifier[pos] operator[<] Other[0] operator[SEP] Keyword[throw] Keyword[new] identifier... |
protected void householder( int j )
{
// find the element with the largest absolute value in the column and make a copy
int index = j+j*numCols;
double max = 0;
for( int i = j; i < numRows; i++ ) {
double d = u[i] = dataQR[index];
// absolute value of d
... | class class_name[name] begin[{]
method[householder, return_type[void], modifier[protected], parameter[j]] begin[{]
local_variable[type[int], index]
local_variable[type[double], max]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declara... | Keyword[protected] Keyword[void] identifier[householder] operator[SEP] Keyword[int] identifier[j] operator[SEP] {
Keyword[int] identifier[index] operator[=] identifier[j] operator[+] identifier[j] operator[*] identifier[numCols] operator[SEP] Keyword[double] identifier[max] operator[=] Other[0] operator[SEP] Key... |
public JSONObject getByAgency(String company, String agency, HashMap<String, String> params) throws JSONException {
return _getByType(company, null, agency, params, false);
} | class class_name[name] begin[{]
method[getByAgency, return_type[type[JSONObject]], modifier[public], parameter[company, agency, params]] begin[{]
return[call[._getByType, parameter[member[.company], literal[null], member[.agency], member[.params], literal[false]]]]
end[}]
END[}] | Keyword[public] identifier[JSONObject] identifier[getByAgency] operator[SEP] identifier[String] identifier[company] , identifier[String] identifier[agency] , identifier[HashMap] operator[<] identifier[String] , identifier[String] operator[>] identifier[params] operator[SEP] Keyword[throws] identifier[JSONException] ... |
public void addLabel(Label label)
{
// Add the label to any applications it is associated with
List<Long> applicationIds = label.getLinks().getApplications();
for(long applicationId : applicationIds)
{
Application application = applications.get(applicationId);
... | class class_name[name] begin[{]
method[addLabel, return_type[void], modifier[public], parameter[label]] begin[{]
local_variable[type[List], applicationIds]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimension... | Keyword[public] Keyword[void] identifier[addLabel] operator[SEP] identifier[Label] identifier[label] operator[SEP] {
identifier[List] operator[<] identifier[Long] operator[>] identifier[applicationIds] operator[=] identifier[label] operator[SEP] identifier[getLinks] operator[SEP] operator[SEP] operator[SEP] iden... |
public static synchronized SocketFactory getDefault() {
// Android-changed: Use security version instead of propertyChecked.
if (defaultSocketFactory != null && lastVersion == Security.getVersion()) {
return defaultSocketFactory;
}
lastVersion = Security.getVersion();
... | class class_name[name] begin[{]
method[getDefault, return_type[type[SocketFactory]], modifier[synchronized public static], parameter[]] begin[{]
if[binary_operation[binary_operation[member[.defaultSocketFactory], !=, literal[null]], &&, binary_operation[member[.lastVersion], ==, call[Security.g... | Keyword[public] Keyword[static] Keyword[synchronized] identifier[SocketFactory] identifier[getDefault] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[defaultSocketFactory] operator[!=] Other[null] operator[&&] identifier[lastVersion] operator[==] identifier[Security] operator[SEP] identifier[... |
protected void updateIndexOffline(I_CmsReport report, List<CmsPublishedResource> resourcesToIndex) {
CmsObject cms = m_adminCms;
try {
// copy the administration context for the indexing
cms = OpenCms.initCmsObject(m_adminCms);
// set site root and project for this i... | class class_name[name] begin[{]
method[updateIndexOffline, return_type[void], modifier[protected], parameter[report, resourcesToIndex]] begin[{]
local_variable[type[CmsObject], cms]
TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(member=cms, postfix_ope... | Keyword[protected] Keyword[void] identifier[updateIndexOffline] operator[SEP] identifier[I_CmsReport] identifier[report] , identifier[List] operator[<] identifier[CmsPublishedResource] operator[>] identifier[resourcesToIndex] operator[SEP] {
identifier[CmsObject] identifier[cms] operator[=] identifier[m_adminCm... |
@RequestMapping(value = "predefinedPromotionLevels", method = RequestMethod.GET)
public Resources<PredefinedPromotionLevel> getPredefinedPromotionLevelList() {
return Resources.of(
predefinedPromotionLevelService.getPredefinedPromotionLevels(),
uri(on(getClass()).getPredefine... | class class_name[name] begin[{]
method[getPredefinedPromotionLevelList, return_type[type[Resources]], modifier[public], parameter[]] begin[{]
return[call[Resources.of, parameter[call[predefinedPromotionLevelService.getPredefinedPromotionLevels, parameter[]], call[.uri, parameter[call[.on, parameter[cal... | annotation[@] identifier[RequestMapping] operator[SEP] identifier[value] operator[=] literal[String] , identifier[method] operator[=] identifier[RequestMethod] operator[SEP] identifier[GET] operator[SEP] Keyword[public] identifier[Resources] operator[<] identifier[PredefinedPromotionLevel] operator[>] identifier[getPr... |
public static void main(String[] args) {
if (args.length != 0) {
LOG.info("java -cp {} {}", RuntimeConstants.ALLUXIO_JAR,
AlluxioProxyMonitor.class.getCanonicalName());
LOG.warn("ignoring arguments");
}
HealthCheckClient client = new ProxyHealthCheckClient(
NetworkAddressUtils... | class class_name[name] begin[{]
method[main, return_type[void], modifier[public static], parameter[args]] begin[{]
if[binary_operation[member[args.length], !=, literal[0]]] begin[{]
call[LOG.info, parameter[literal["java -cp {} {}"], member[RuntimeConstants.ALLUXIO_JAR],... | Keyword[public] Keyword[static] Keyword[void] identifier[main] operator[SEP] identifier[String] operator[SEP] operator[SEP] identifier[args] operator[SEP] {
Keyword[if] operator[SEP] identifier[args] operator[SEP] identifier[length] operator[!=] Other[0] operator[SEP] {
identifier[LOG] operator[SEP] i... |
public List<AuthenticationMechanism<Resourceadapter<T>>> getAllAuthenticationMechanism()
{
List<AuthenticationMechanism<Resourceadapter<T>>> list = new ArrayList<AuthenticationMechanism<Resourceadapter<T>>>();
List<Node> nodeList = childNode.get("authentication-mechanism");
for(Node node: nodeList)... | class class_name[name] begin[{]
method[getAllAuthenticationMechanism, return_type[type[List]], modifier[public], parameter[]] begin[{]
local_variable[type[List], list]
local_variable[type[List], nodeList]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(... | Keyword[public] identifier[List] operator[<] identifier[AuthenticationMechanism] operator[<] identifier[Resourceadapter] operator[<] identifier[T] operator[>] operator[>] operator[>] identifier[getAllAuthenticationMechanism] operator[SEP] operator[SEP] {
identifier[List] operator[<] identifier[AuthenticationMech... |
String getCreateParams() {
if (!locale_set) {
setLocale(Locale.getDefault());
}
String names;
switch (type) {
case Types.SQL_BINARY :
case Types.SQL_CHAR :
case Types.SQL_NCHAR :
case Types.SQL_CLOB :
case Types.... | class class_name[name] begin[{]
method[getCreateParams, return_type[type[String]], modifier[default], parameter[]] begin[{]
if[member[.locale_set]] begin[{]
call[.setLocale, parameter[call[Locale.getDefault, parameter[]]]]
else begin[{]
None
end[}]
... | identifier[String] identifier[getCreateParams] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[locale_set] operator[SEP] {
identifier[setLocale] operator[SEP] identifier[Locale] operator[SEP] identifier[getDefault] operator[SEP] operator[SEP] operator[SEP] operator[SEP] ... |
public static <T> void mergeFrom(JsonParser parser, T message, Schema<T> schema,
boolean numeric) throws IOException
{
if (parser.nextToken() != JsonToken.START_OBJECT)
{
throw new JsonInputException("Expected token: { but was " +
parser.getCurrentTo... | class class_name[name] begin[{]
method[mergeFrom, return_type[void], modifier[public static], parameter[parser, message, schema, numeric]] begin[{]
if[binary_operation[call[parser.nextToken, parameter[]], !=, member[JsonToken.START_OBJECT]]] begin[{]
ThrowStatement(expression=ClassC... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] Keyword[void] identifier[mergeFrom] operator[SEP] identifier[JsonParser] identifier[parser] , identifier[T] identifier[message] , identifier[Schema] operator[<] identifier[T] operator[>] identifier[schema] , Keyword[boolean] identifier[numeric] op... |
private void setCustomTypeface(Context context, AttributeSet attrs) {
DEFAULT_TYPEFACE = TypefaceType.getDefaultTypeface(context);
//Typeface.createFromAsset doesn't work in the layout editor. Skipping...
if (isInEditMode() || attrs == null || Build.VERSION.SDK_INT < Build.VERSION_CODES.HONEYCO... | class class_name[name] begin[{]
method[setCustomTypeface, return_type[void], modifier[private], parameter[context, attrs]] begin[{]
assign[member[.DEFAULT_TYPEFACE], call[TypefaceType.getDefaultTypeface, parameter[member[.context]]]]
if[binary_operation[binary_operation[call[.is... | Keyword[private] Keyword[void] identifier[setCustomTypeface] operator[SEP] identifier[Context] identifier[context] , identifier[AttributeSet] identifier[attrs] operator[SEP] {
identifier[DEFAULT_TYPEFACE] operator[=] identifier[TypefaceType] operator[SEP] identifier[getDefaultTypeface] operator[SEP] identifier[... |
public DiscoverItems discoverItems(Jid entityID) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
return discoverItems(entityID, null);
} | class class_name[name] begin[{]
method[discoverItems, return_type[type[DiscoverItems]], modifier[public], parameter[entityID]] begin[{]
return[call[.discoverItems, parameter[member[.entityID], literal[null]]]]
end[}]
END[}] | Keyword[public] identifier[DiscoverItems] identifier[discoverItems] operator[SEP] identifier[Jid] identifier[entityID] operator[SEP] Keyword[throws] identifier[NoResponseException] , identifier[XMPPErrorException] , identifier[NotConnectedException] , identifier[InterruptedException] {
Keyword[return] identif... |
public void scheduleAtFixedRate(TimerTask task, Date firstTime,
long period) {
if (period <= 0)
throw new IllegalArgumentException("Non-positive period.");
sched(task, firstTime.getTime(), period);
} | class class_name[name] begin[{]
method[scheduleAtFixedRate, return_type[void], modifier[public], parameter[task, firstTime, period]] begin[{]
if[binary_operation[member[.period], <=, literal[0]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_ope... | Keyword[public] Keyword[void] identifier[scheduleAtFixedRate] operator[SEP] identifier[TimerTask] identifier[task] , identifier[Date] identifier[firstTime] , Keyword[long] identifier[period] operator[SEP] {
Keyword[if] operator[SEP] identifier[period] operator[<=] Other[0] operator[SEP] Keyword[throw] Keyword[... |
public ServiceFuture<List<SiteInner>> resumeAsync(final String resourceGroupName, final String name, final ListOperationCallback<SiteInner> serviceCallback) {
return AzureServiceFuture.fromPageResponse(
resumeSinglePageAsync(resourceGroupName, name),
new Func1<String, Observable<ServiceR... | class class_name[name] begin[{]
method[resumeAsync, return_type[type[ServiceFuture]], modifier[public], parameter[resourceGroupName, name, serviceCallback]] begin[{]
return[call[AzureServiceFuture.fromPageResponse, parameter[call[.resumeSinglePageAsync, parameter[member[.resourceGroupName], member[.nam... | Keyword[public] identifier[ServiceFuture] operator[<] identifier[List] operator[<] identifier[SiteInner] operator[>] operator[>] identifier[resumeAsync] operator[SEP] Keyword[final] identifier[String] identifier[resourceGroupName] , Keyword[final] identifier[String] identifier[name] , Keyword[final] identifier[ListOp... |
public void marshall(UntagResourceRequest untagResourceRequest, ProtocolMarshaller protocolMarshaller) {
if (untagResourceRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(untagResourceReques... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[untagResourceRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.untagResourceRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Liter... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[UntagResourceRequest] identifier[untagResourceRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[untagResourceRequest] operator[==] Other[null] operator[SEP] {
... |
@Override
public boolean modelBuilderClassGenerated(TopLevelClass topLevelClass, InnerClass builderClass, List<IntrospectedColumn> columns, IntrospectedTable introspectedTable) {
for (IModelBuilderPluginHook plugin : this.getPlugins(IModelBuilderPluginHook.class)) {
if (!plugin.modelBuilderClass... | class class_name[name] begin[{]
method[modelBuilderClassGenerated, return_type[type[boolean]], modifier[public], parameter[topLevelClass, builderClass, columns, introspectedTable]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[Member... | annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[modelBuilderClassGenerated] operator[SEP] identifier[TopLevelClass] identifier[topLevelClass] , identifier[InnerClass] identifier[builderClass] , identifier[List] operator[<] identifier[IntrospectedColumn] operator[>] identifier[columns] ,... |
protected SIDestinationAddress getProducerSIDestinationAddress() throws JMSException {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
SibTr.entry(this, tc, "getProducerSIDestinationAddress");
if (producerDestinationAddress == null) {
if (TraceComponent.isAnyTra... | class class_name[name] begin[{]
method[getProducerSIDestinationAddress, return_type[type[SIDestinationAddress]], modifier[protected], parameter[]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{]
... | Keyword[protected] identifier[SIDestinationAddress] identifier[getProducerSIDestinationAddress] operator[SEP] operator[SEP] Keyword[throws] identifier[JMSException] {
Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identi... |
@Override
public Object evaluate( Message message ) throws JMSException
{
// Standard headers
if (name.equals("JMSCorrelationID"))
return message.getJMSCorrelationID();
if (name.equals("JMSMessageID"))
return message.getJMSMessageID();
if (name.equals("JMSTyp... | class class_name[name] begin[{]
method[evaluate, return_type[type[Object]], modifier[public], parameter[message]] begin[{]
if[call[name.equals, parameter[literal["JMSCorrelationID"]]]] begin[{]
return[call[message.getJMSCorrelationID, parameter[]]]
else begin[{]
None
end[}]
... | annotation[@] identifier[Override] Keyword[public] identifier[Object] identifier[evaluate] operator[SEP] identifier[Message] identifier[message] operator[SEP] Keyword[throws] identifier[JMSException] {
Keyword[if] operator[SEP] identifier[name] operator[SEP] identifier[equals] operator[SEP] literal[String] opera... |
Rule IfieldHistory() {
return Sequence(String("[H:"),
ZeroOrMore(WSP()).suppressNode(),
TexTextIfield(),
String("]"))
.label(IfieldHistory);
} | class class_name[name] begin[{]
method[IfieldHistory, return_type[type[Rule]], modifier[default], parameter[]] begin[{]
return[call[.Sequence, parameter[call[.String, parameter[literal["[H:"]]], call[.ZeroOrMore, parameter[call[.WSP, parameter[]]]], call[.TexTextIfield, parameter[]], call[.String, para... | identifier[Rule] identifier[IfieldHistory] operator[SEP] operator[SEP] {
Keyword[return] identifier[Sequence] operator[SEP] identifier[String] operator[SEP] literal[String] operator[SEP] , identifier[ZeroOrMore] operator[SEP] identifier[WSP] operator[SEP] operator[SEP] operator[SEP] operator[SEP] identifier[sup... |
public Section getSubSection(int i){
if( sections.size() > i ) return sections.get(i);
else return null;
} | class class_name[name] begin[{]
method[getSubSection, return_type[type[Section]], modifier[public], parameter[i]] begin[{]
if[binary_operation[call[sections.size, parameter[]], >, member[.i]]] begin[{]
return[call[sections.get, parameter[member[.i]]]]
else begin[{]
return[literal[null]]... | Keyword[public] identifier[Section] identifier[getSubSection] operator[SEP] Keyword[int] identifier[i] operator[SEP] {
Keyword[if] operator[SEP] identifier[sections] operator[SEP] identifier[size] operator[SEP] operator[SEP] operator[>] identifier[i] operator[SEP] Keyword[return] identifier[sections] operator[SE... |
public File getParentFile() {
String tempParent = getParent();
if (tempParent == null) {
return null;
}
return new File(tempParent);
} | class class_name[name] begin[{]
method[getParentFile, return_type[type[File]], modifier[public], parameter[]] begin[{]
local_variable[type[String], tempParent]
if[binary_operation[member[.tempParent], ==, literal[null]]] begin[{]
return[literal[null]]
else begin[{]
N... | Keyword[public] identifier[File] identifier[getParentFile] operator[SEP] operator[SEP] {
identifier[String] identifier[tempParent] operator[=] identifier[getParent] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[tempParent] operator[==] Other[null] operator[SEP] {
Keywo... |
public void setImageUrls(final String... imageUrls) {
if (imageUrls == null) {
throw new NullValueException("imageUrls is null");
}
final StringBuilder sb = new StringBuilder();
for (int i = 0; i < imageUrls.length; i++) {
sb.append("url(\"").append(imageUrls[i]).... | class class_name[name] begin[{]
method[setImageUrls, return_type[void], modifier[public], parameter[imageUrls]] begin[{]
if[binary_operation[member[.imageUrls], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operat... | Keyword[public] Keyword[void] identifier[setImageUrls] operator[SEP] Keyword[final] identifier[String] operator[...] identifier[imageUrls] operator[SEP] {
Keyword[if] operator[SEP] identifier[imageUrls] operator[==] Other[null] operator[SEP] {
Keyword[throw] Keyword[new] identifier[NullValueException]... |
public void merge() {
Thread currentThread = Thread.currentThread();
if(!stats.get(currentThread).equals(this) || currentThread instanceof WindupChildThread) {
throw new IllegalArgumentException("Trying to merge executionstatistics from a "
+ "different thread that is... | class class_name[name] begin[{]
method[merge, return_type[void], modifier[public], parameter[]] begin[{]
local_variable[type[Thread], currentThread]
if[binary_operation[call[stats.get, parameter[member[.currentThread]]], ||, binary_operation[member[.currentThread], instanceof, type[Wind... | Keyword[public] Keyword[void] identifier[merge] operator[SEP] operator[SEP] {
identifier[Thread] identifier[currentThread] operator[=] identifier[Thread] operator[SEP] identifier[currentThread] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] operator[!] identifier[stats] operator[SEP] identif... |
protected List<Rule> parsePattern() {
final DateFormatSymbols symbols = new DateFormatSymbols(locale);
final List<Rule> rules = new ArrayList<>();
final String[] ERAs = symbols.getEras();
final String[] months = symbols.getMonths();
final String[] shortMonths = symbols.getShortMonths();
final String[] week... | class class_name[name] begin[{]
method[parsePattern, return_type[type[List]], modifier[protected], parameter[]] begin[{]
local_variable[type[DateFormatSymbols], symbols]
local_variable[type[List], rules]
local_variable[type[String], ERAs]
local_variable[type[String], months]
... | Keyword[protected] identifier[List] operator[<] identifier[Rule] operator[>] identifier[parsePattern] operator[SEP] operator[SEP] {
Keyword[final] identifier[DateFormatSymbols] identifier[symbols] operator[=] Keyword[new] identifier[DateFormatSymbols] operator[SEP] identifier[locale] operator[SEP] operator[SEP] ... |
protected void fromJson(JSONObject json) throws JSONException {
super.fromJson(json);
JSONObject details = json.getJSONObject(DETAILS_KEY);
mEmail = Json.optString(details, EMAIL_KEY, null);
mClientMetadataId = Json.optString(details, CLIENT_METADATA_ID_KEY, null);
mType = Json.... | class class_name[name] begin[{]
method[fromJson, return_type[void], modifier[protected], parameter[json]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=json, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], member=fromJson, postfix_operators=[], prefix_o... | Keyword[protected] Keyword[void] identifier[fromJson] operator[SEP] identifier[JSONObject] identifier[json] operator[SEP] Keyword[throws] identifier[JSONException] {
Keyword[super] operator[SEP] identifier[fromJson] operator[SEP] identifier[json] operator[SEP] operator[SEP] identifier[JSONObject] identifier[deta... |
@SuppressWarnings("unchecked")
protected List<String> mergeRoles(List<String> otherRoles, boolean mergedAccessPrecluded) {
if (mergedAccessPrecluded == true || roles.isEmpty() || otherRoles.isEmpty()) {
return Collections.EMPTY_LIST;
}
Set<String> tempRoles = new HashSet<String>(... | class class_name[name] begin[{]
method[mergeRoles, return_type[type[List]], modifier[protected], parameter[otherRoles, mergedAccessPrecluded]] begin[{]
if[binary_operation[binary_operation[binary_operation[member[.mergedAccessPrecluded], ==, literal[true]], ||, call[roles.isEmpty, parameter[]]]... | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[protected] identifier[List] operator[<] identifier[String] operator[>] identifier[mergeRoles] operator[SEP] identifier[List] operator[<] identifier[String] operator[>] identifier[otherRoles] , Keyword[boolean] identifier[mer... |
public void marshall(DescribeRiskConfigurationRequest describeRiskConfigurationRequest, ProtocolMarshaller protocolMarshaller) {
if (describeRiskConfigurationRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMar... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[describeRiskConfigurationRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.describeRiskConfigurationRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=Class... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[DescribeRiskConfigurationRequest] identifier[describeRiskConfigurationRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[describeRiskConfigurationRequest] operat... |
public TradingRecord run(Strategy strategy, OrderType orderType, Decimal amount) {
return run(strategy, orderType, amount, timeSeries.getBeginIndex(), timeSeries.getEndIndex());
} | class class_name[name] begin[{]
method[run, return_type[type[TradingRecord]], modifier[public], parameter[strategy, orderType, amount]] begin[{]
return[call[.run, parameter[member[.strategy], member[.orderType], member[.amount], call[timeSeries.getBeginIndex, parameter[]], call[timeSeries.getEndIndex, ... | Keyword[public] identifier[TradingRecord] identifier[run] operator[SEP] identifier[Strategy] identifier[strategy] , identifier[OrderType] identifier[orderType] , identifier[Decimal] identifier[amount] operator[SEP] {
Keyword[return] identifier[run] operator[SEP] identifier[strategy] , identifier[orderType] , ... |
public boolean isInHead()
{
PositionalTermTraverserImpl.PositionalContextOperator position = contextStack.peek();
return (position != null) && position.isInHead();
} | class class_name[name] begin[{]
method[isInHead, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
local_variable[type[PositionalTermTraverserImpl], position]
return[binary_operation[binary_operation[member[.position], !=, literal[null]], &&, call[position.isInHead, parameter[... | Keyword[public] Keyword[boolean] identifier[isInHead] operator[SEP] operator[SEP] {
identifier[PositionalTermTraverserImpl] operator[SEP] identifier[PositionalContextOperator] identifier[position] operator[=] identifier[contextStack] operator[SEP] identifier[peek] operator[SEP] operator[SEP] operator[SEP] Keywor... |
public static BigDecimal add(Number v1, Number v2) {
return add(new Number[] { v1, v2 });
} | class class_name[name] begin[{]
method[add, return_type[type[BigDecimal]], modifier[public static], parameter[v1, v2]] begin[{]
return[call[.add, parameter[ArrayCreator(dimensions=[None], initializer=ArrayInitializer(initializers=[MemberReference(member=v1, postfix_operators=[], prefix_operators=[], qu... | Keyword[public] Keyword[static] identifier[BigDecimal] identifier[add] operator[SEP] identifier[Number] identifier[v1] , identifier[Number] identifier[v2] operator[SEP] {
Keyword[return] identifier[add] operator[SEP] Keyword[new] identifier[Number] operator[SEP] operator[SEP] {
identifier[v1] , iden... |
public final long fromBitString2Long(String str) {
if (str.length() > 64)
throw new UnsupportedOperationException("Strings needs to fit into a 'long' but length was " + str.length());
long res = 0;
int strLen = str.length();
for (int charIndex = 0; charIndex < strLen; charIn... | class class_name[name] begin[{]
method[fromBitString2Long, return_type[type[long]], modifier[final public], parameter[str]] begin[{]
if[binary_operation[call[str.length, parameter[]], >, literal[64]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[BinaryOperation(operandl=Literal(po... | Keyword[public] Keyword[final] Keyword[long] identifier[fromBitString2Long] operator[SEP] identifier[String] identifier[str] operator[SEP] {
Keyword[if] operator[SEP] identifier[str] operator[SEP] identifier[length] operator[SEP] operator[SEP] operator[>] Other[64] operator[SEP] Keyword[throw] Keyword[new] ident... |
public void write(byte[] b, int off, int len) throws IOException {
count += len;
super.write(b, off, len);
} | class class_name[name] begin[{]
method[write, return_type[void], modifier[public], parameter[b, off, len]] begin[{]
assign[member[.count], member[.len]]
SuperMethodInvocation(arguments=[MemberReference(member=b, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]... | Keyword[public] Keyword[void] identifier[write] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[b] , Keyword[int] identifier[off] , Keyword[int] identifier[len] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[count] operator[+=] identifier[len] operator[SEP] Keyword[super]... |
public DirectedSparseMultigraph<TrajectoryEnvelope,Integer[]> getCurrentDependencies() {
DirectedSparseMultigraph<TrajectoryEnvelope,Integer[]> depGraph = new DirectedSparseMultigraph<TrajectoryEnvelope,Integer[]>();
ConstraintNetwork cn = this.getConstraintSolvers()[0].getConstraintNetwork();
Constraint[] con... | class class_name[name] begin[{]
method[getCurrentDependencies, return_type[type[DirectedSparseMultigraph]], modifier[public], parameter[]] begin[{]
local_variable[type[DirectedSparseMultigraph], depGraph]
local_variable[type[ConstraintNetwork], cn]
local_variable[type[Constraint], cons]... | Keyword[public] identifier[DirectedSparseMultigraph] operator[<] identifier[TrajectoryEnvelope] , identifier[Integer] operator[SEP] operator[SEP] operator[>] identifier[getCurrentDependencies] operator[SEP] operator[SEP] {
identifier[DirectedSparseMultigraph] operator[<] identifier[TrajectoryEnvelope] , identi... |
public void marshall(BlackoutSlate blackoutSlate, ProtocolMarshaller protocolMarshaller) {
if (blackoutSlate == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(blackoutSlate.getBlackoutSlateImage(), B... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[blackoutSlate, protocolMarshaller]] begin[{]
if[binary_operation[member[.blackoutSlate], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_ope... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[BlackoutSlate] identifier[blackoutSlate] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[blackoutSlate] operator[==] Other[null] operator[SEP] {
Keyword[thr... |
public byte[] simpleSerial(){
byte[] out = new byte[text.length + iv.length + 1];
out[0] = (byte) iv.length;
System.arraycopy(iv, 0, out, 1, iv.length);
System.arraycopy(text, 0, out, iv.length + 1, text.length);
return out;
} | class class_name[name] begin[{]
method[simpleSerial, return_type[type[byte]], modifier[public], parameter[]] begin[{]
local_variable[type[byte], out]
assign[member[.out], Cast(expression=MemberReference(member=length, postfix_operators=[], prefix_operators=[], qualifier=iv, selectors=[]... | Keyword[public] Keyword[byte] operator[SEP] operator[SEP] identifier[simpleSerial] operator[SEP] operator[SEP] {
Keyword[byte] operator[SEP] operator[SEP] identifier[out] operator[=] Keyword[new] Keyword[byte] operator[SEP] identifier[text] operator[SEP] identifier[length] operator[+] identifier[iv] operator[SEP... |
@Override
public void onReceiveSuggestionsResult(@NonNull SuggestionsResult result, @NonNull String bucket) {
List<? extends Suggestible> suggestions = result.getSuggestions();
adapter = new PersonMentionAdapter(result.getSuggestions());
recyclerView.swapAdapter(adapter, true);
boole... | class class_name[name] begin[{]
method[onReceiveSuggestionsResult, return_type[void], modifier[public], parameter[result, bucket]] begin[{]
local_variable[type[List], suggestions]
assign[member[.adapter], ClassCreator(arguments=[MethodInvocation(arguments=[], member=getSuggestions, post... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[onReceiveSuggestionsResult] operator[SEP] annotation[@] identifier[NonNull] identifier[SuggestionsResult] identifier[result] , annotation[@] identifier[NonNull] identifier[String] identifier[bucket] operator[SEP] {
identifier[List] oper... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.