code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public List<T> hasValue(String property, String value) {
List<T> geoPackages = new ArrayList<>();
for (PropertiesCoreExtension<T, ?, ?, ?> properties : propertiesMap
.values()) {
if (properties.hasValue(property, value)) {
geoPackages.add(properties.getGeoPackage());
}
}
return geoPackages;
} | class class_name[name] begin[{]
method[hasValue, return_type[type[List]], modifier[public], parameter[property, value]] begin[{]
local_variable[type[List], geoPackages]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(mem... | Keyword[public] identifier[List] operator[<] identifier[T] operator[>] identifier[hasValue] operator[SEP] identifier[String] identifier[property] , identifier[String] identifier[value] operator[SEP] {
identifier[List] operator[<] identifier[T] operator[>] identifier[geoPackages] operator[=] Keyword[new] identif... |
public static String[] toStrings(SymbolToken[] symbols, int count)
{
if (count == 0) return _Private_Utils.EMPTY_STRING_ARRAY;
String[] annotations = new String[count];
for (int i = 0; i < count; i++)
{
SymbolToken tok = symbols[i];
String text = tok.getText(... | class class_name[name] begin[{]
method[toStrings, return_type[type[String]], modifier[public static], parameter[symbols, count]] begin[{]
if[binary_operation[member[.count], ==, literal[0]]] begin[{]
return[member[_Private_Utils.EMPTY_STRING_ARRAY]]
else begin[{]
None
end[}]
... | Keyword[public] Keyword[static] identifier[String] operator[SEP] operator[SEP] identifier[toStrings] operator[SEP] identifier[SymbolToken] operator[SEP] operator[SEP] identifier[symbols] , Keyword[int] identifier[count] operator[SEP] {
Keyword[if] operator[SEP] identifier[count] operator[==] Other[0] operator[S... |
public static void callAnnotated(Object o, Class<? extends Annotation> ann, boolean lazy) {
try {
getMethodOfInterest(o, ann).invoke(o);
} catch (IllegalAccessException ex) {
throw new RuntimeException(ex);
} catch (InvocationTargetException ex) {
throw new Ru... | class class_name[name] begin[{]
method[callAnnotated, return_type[void], modifier[public static], parameter[o, ann, lazy]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=o, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[... | Keyword[public] Keyword[static] Keyword[void] identifier[callAnnotated] operator[SEP] identifier[Object] identifier[o] , identifier[Class] operator[<] operator[?] Keyword[extends] identifier[Annotation] operator[>] identifier[ann] , Keyword[boolean] identifier[lazy] operator[SEP] {
Keyword[try] {
id... |
public static ModelNode createUndefineAttributeOperation(PathAddress address, String name) {
return createAttributeOperation(ModelDescriptionConstants.UNDEFINE_ATTRIBUTE_OPERATION, address, name);
} | class class_name[name] begin[{]
method[createUndefineAttributeOperation, return_type[type[ModelNode]], modifier[public static], parameter[address, name]] begin[{]
return[call[.createAttributeOperation, parameter[member[ModelDescriptionConstants.UNDEFINE_ATTRIBUTE_OPERATION], member[.address], member[.n... | Keyword[public] Keyword[static] identifier[ModelNode] identifier[createUndefineAttributeOperation] operator[SEP] identifier[PathAddress] identifier[address] , identifier[String] identifier[name] operator[SEP] {
Keyword[return] identifier[createAttributeOperation] operator[SEP] identifier[ModelDescriptionConstan... |
public String queryString() {
if (query == null) {
return StringPool.EMPTY;
}
return HttpUtil.buildQuery(query, queryEncoding);
} | class class_name[name] begin[{]
method[queryString, return_type[type[String]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.query], ==, literal[null]]] begin[{]
return[member[StringPool.EMPTY]]
else begin[{]
None
end[}]
return[call[Http... | Keyword[public] identifier[String] identifier[queryString] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[query] operator[==] Other[null] operator[SEP] {
Keyword[return] identifier[StringPool] operator[SEP] identifier[EMPTY] operator[SEP]
}
Keyword[return] identifier[... |
public void init(Object parent, Object strURL)
{
super.init(parent, strURL);
this.setLayout(new BorderLayout());
BaseApplet applet = null;
if (strURL instanceof BaseApplet)
applet = (BaseApplet)strURL;
if (applet == null)
applet = this.getBas... | class class_name[name] begin[{]
method[init, return_type[void], modifier[public], parameter[parent, strURL]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=parent, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(member=strURL, postfix_oper... | Keyword[public] Keyword[void] identifier[init] operator[SEP] identifier[Object] identifier[parent] , identifier[Object] identifier[strURL] operator[SEP] {
Keyword[super] operator[SEP] identifier[init] operator[SEP] identifier[parent] , identifier[strURL] operator[SEP] operator[SEP] Keyword[this] operator[SEP] ... |
private Animation createAnimation(MovingParams params) {
Animation animation = new TranslateAnimation(0, params.getXAxisDelta(), 0, params.getYAxisDelta());
animation.setFillEnabled(true);
animation.setFillBefore(false);
animation.setDuration(params.getAnimationDuration());
Interpolator interpolator = params.... | class class_name[name] begin[{]
method[createAnimation, return_type[type[Animation]], modifier[private], parameter[params]] begin[{]
local_variable[type[Animation], animation]
call[animation.setFillEnabled, parameter[literal[true]]]
call[animation.setFillBefore, paramete... | Keyword[private] identifier[Animation] identifier[createAnimation] operator[SEP] identifier[MovingParams] identifier[params] operator[SEP] {
identifier[Animation] identifier[animation] operator[=] Keyword[new] identifier[TranslateAnimation] operator[SEP] Other[0] , identifier[params] operator[SEP] identifier[ge... |
private CallStatus beforePromotion() {
NodeEngineImpl nodeEngine = (NodeEngineImpl) getNodeEngine();
InternalOperationService operationService = nodeEngine.getOperationService();
InternalPartitionServiceImpl partitionService = getService();
if (!partitionService.getMigrationManager().ac... | class class_name[name] begin[{]
method[beforePromotion, return_type[type[CallStatus]], modifier[private], parameter[]] begin[{]
local_variable[type[NodeEngineImpl], nodeEngine]
local_variable[type[InternalOperationService], operationService]
local_variable[type[InternalPartitionServiceI... | Keyword[private] identifier[CallStatus] identifier[beforePromotion] operator[SEP] operator[SEP] {
identifier[NodeEngineImpl] identifier[nodeEngine] operator[=] operator[SEP] identifier[NodeEngineImpl] operator[SEP] identifier[getNodeEngine] operator[SEP] operator[SEP] operator[SEP] identifier[InternalOperationSe... |
private Asset getInlineAsset(Resource ntResourceResource, Media media, String fileName) {
return new InlineAsset(ntResourceResource, media, fileName, adaptable);
} | class class_name[name] begin[{]
method[getInlineAsset, return_type[type[Asset]], modifier[private], parameter[ntResourceResource, media, fileName]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=ntResourceResource, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), Me... | Keyword[private] identifier[Asset] identifier[getInlineAsset] operator[SEP] identifier[Resource] identifier[ntResourceResource] , identifier[Media] identifier[media] , identifier[String] identifier[fileName] operator[SEP] {
Keyword[return] Keyword[new] identifier[InlineAsset] operator[SEP] identifier[ntResourc... |
public static long getHoursDifference(Date startDate, Date endDate) {
long startTime = startDate.getTime();
long endTime = endDate.getTime();
long diffTime = endTime - startTime;
long diffInHours = TimeUnit.MILLISECONDS.toHours(diffTime);
return diffInHours;
} | class class_name[name] begin[{]
method[getHoursDifference, return_type[type[long]], modifier[public static], parameter[startDate, endDate]] begin[{]
local_variable[type[long], startTime]
local_variable[type[long], endTime]
local_variable[type[long], diffTime]
local_variable[type... | Keyword[public] Keyword[static] Keyword[long] identifier[getHoursDifference] operator[SEP] identifier[Date] identifier[startDate] , identifier[Date] identifier[endDate] operator[SEP] {
Keyword[long] identifier[startTime] operator[=] identifier[startDate] operator[SEP] identifier[getTime] operator[SEP] operator[... |
public static ConnectionHandler register(final String id,
final ConnectionHandler handler) {
if (id == null || id.length() == 0) {
throw new IllegalArgumentException("Invalid ID: " + id);
} // end of if
if (handler == null) {
... | class class_name[name] begin[{]
method[register, return_type[type[ConnectionHandler]], modifier[public static], parameter[id, handler]] begin[{]
if[binary_operation[binary_operation[member[.id], ==, literal[null]], ||, binary_operation[call[id.length, parameter[]], ==, literal[0]]]] begin[{]
... | Keyword[public] Keyword[static] identifier[ConnectionHandler] identifier[register] operator[SEP] Keyword[final] identifier[String] identifier[id] , Keyword[final] identifier[ConnectionHandler] identifier[handler] operator[SEP] {
Keyword[if] operator[SEP] identifier[id] operator[==] Other[null] operator[||] iden... |
public static File copyIntoTempFile(String fileName, InputStream inputStream)
throws IOException {
BufferedInputStream bufferedStream = inputStream instanceof BufferedInputStream ? (BufferedInputStream) inputStream
: new BufferedInputStream(inputStream);
File destFile = null;
try {
destF... | class class_name[name] begin[{]
method[copyIntoTempFile, return_type[type[File]], modifier[public static], parameter[fileName, inputStream]] begin[{]
local_variable[type[BufferedInputStream], bufferedStream]
local_variable[type[File], destFile]
TryStatement(block=[StatementExpression(ex... | Keyword[public] Keyword[static] identifier[File] identifier[copyIntoTempFile] operator[SEP] identifier[String] identifier[fileName] , identifier[InputStream] identifier[inputStream] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[BufferedInputStream] identifier[bufferedStream] operator[=] ide... |
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case AfplibPackage.TILE_TOCRG__XOFFSET:
setXOFFSET((Integer)newValue);
return;
case AfplibPackage.TILE_TOCRG__YOFFSET:
setYOFFSET((Integer)newValue);
return;
case AfplibPackage.TILE_TOCRG__THSIZE:
setTHSIZE... | class class_name[name] begin[{]
method[eSet, return_type[void], modifier[public], parameter[featureID, newValue]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=TILE_TOCRG__XOFFSET, postfix_operators=[], prefix_operators=[], qualifier=AfplibPackage, selectors=[])], sta... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[eSet] operator[SEP] Keyword[int] identifier[featureID] , identifier[Object] identifier[newValue] operator[SEP] {
Keyword[switch] operator[SEP] identifier[featureID] operator[SEP] {
Keyword[case] identifier[AfplibPackage] oper... |
public ApplicationDetail withCloudWatchLoggingOptionDescriptions(CloudWatchLoggingOptionDescription... cloudWatchLoggingOptionDescriptions) {
if (this.cloudWatchLoggingOptionDescriptions == null) {
setCloudWatchLoggingOptionDescriptions(new java.util.ArrayList<CloudWatchLoggingOptionDescription>(clo... | class class_name[name] begin[{]
method[withCloudWatchLoggingOptionDescriptions, return_type[type[ApplicationDetail]], modifier[public], parameter[cloudWatchLoggingOptionDescriptions]] begin[{]
if[binary_operation[THIS[member[None.cloudWatchLoggingOptionDescriptions]], ==, literal[null]]] begin[... | Keyword[public] identifier[ApplicationDetail] identifier[withCloudWatchLoggingOptionDescriptions] operator[SEP] identifier[CloudWatchLoggingOptionDescription] operator[...] identifier[cloudWatchLoggingOptionDescriptions] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[cloudWatchL... |
public static void write( Document bson,
OutputStream stream ) throws IOException {
getBsonWriter().write(bson, stream);
} | class class_name[name] begin[{]
method[write, return_type[void], modifier[public static], parameter[bson, stream]] begin[{]
call[.getBsonWriter, parameter[]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[void] identifier[write] operator[SEP] identifier[Document] identifier[bson] , identifier[OutputStream] identifier[stream] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[getBsonWriter] operator[SEP] operator[SEP] operator[SEP] identifier[write] operator... |
private XML checksAttributesExistence(Class<?> aClass,Attribute[] attributes){
String[] attributesNames = new String[attributes.length];
for (int i = attributes.length; i --> 0;)
attributesNames[i] = attributes[i].getName();
checksAttributesExistence(aClass,attributesNames);
return this;
} | class class_name[name] begin[{]
method[checksAttributesExistence, return_type[type[XML]], modifier[private], parameter[aClass, attributes]] begin[{]
local_variable[type[String], attributesNames]
ForStatement(body=StatementExpression(expression=Assignment(expressionl=MemberReference(member=attri... | Keyword[private] identifier[XML] identifier[checksAttributesExistence] operator[SEP] identifier[Class] operator[<] operator[?] operator[>] identifier[aClass] , identifier[Attribute] operator[SEP] operator[SEP] identifier[attributes] operator[SEP] {
identifier[String] operator[SEP] operator[SEP] identifier[attri... |
@Override
public Collection<String> getSlaveDataSourceNames() {
if (disabledDataSourceNames.isEmpty()) {
return super.getSlaveDataSourceNames();
}
Collection<String> result = new LinkedList<>(super.getSlaveDataSourceNames());
result.removeAll(disabledDataSourceNames);
... | class class_name[name] begin[{]
method[getSlaveDataSourceNames, return_type[type[Collection]], modifier[public], parameter[]] begin[{]
if[call[disabledDataSourceNames.isEmpty, parameter[]]] begin[{]
return[SuperMethodInvocation(arguments=[], member=getSlaveDataSourceNames, postfix_o... | annotation[@] identifier[Override] Keyword[public] identifier[Collection] operator[<] identifier[String] operator[>] identifier[getSlaveDataSourceNames] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[disabledDataSourceNames] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operat... |
public static <E, C extends Counter<E>> C L2Normalize(C c) {
return scale(c, 1.0 / L2Norm(c));
} | class class_name[name] begin[{]
method[L2Normalize, return_type[type[C]], modifier[public static], parameter[c]] begin[{]
return[call[.scale, parameter[member[.c], binary_operation[literal[1.0], /, call[.L2Norm, parameter[member[.c]]]]]]]
end[}]
END[}] | Keyword[public] Keyword[static] operator[<] identifier[E] , identifier[C] Keyword[extends] identifier[Counter] operator[<] identifier[E] operator[>] operator[>] identifier[C] identifier[L2Normalize] operator[SEP] identifier[C] identifier[c] operator[SEP] {
Keyword[return] identifier[scale] operator[SEP] identif... |
public boolean goBack() {
if (_entries.size() > 0 &&
(_entries.get(0).getName().equals(".."))) {
_list.performItemClick(_list, 0, 0);
return true;
}
return false;
} | class class_name[name] begin[{]
method[goBack, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
if[binary_operation[binary_operation[call[_entries.size, parameter[]], >, literal[0]], &&, call[_entries.get, parameter[literal[0]]]]] begin[{]
call[_list.p... | Keyword[public] Keyword[boolean] identifier[goBack] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[_entries] operator[SEP] identifier[size] operator[SEP] operator[SEP] operator[>] Other[0] operator[&&] operator[SEP] identifier[_entries] operator[SEP] identifier[get] operator[SEP] Other[0] ope... |
@FFDCIgnore(PrivilegedActionException.class)
private void resolveListenerAddress() throws PrivilegedActionException {
if (host == null) {
try {
host = AccessController.doPrivileged(new PrivilegedExceptionAction<String>() {
@Override
public ... | class class_name[name] begin[{]
method[resolveListenerAddress, return_type[void], modifier[private], parameter[]] begin[{]
if[binary_operation[member[.host], ==, literal[null]]] begin[{]
TryStatement(block=[StatementExpression(expression=Assignment(expressionl=MemberReference(member... | annotation[@] identifier[FFDCIgnore] operator[SEP] identifier[PrivilegedActionException] operator[SEP] Keyword[class] operator[SEP] Keyword[private] Keyword[void] identifier[resolveListenerAddress] operator[SEP] operator[SEP] Keyword[throws] identifier[PrivilegedActionException] {
Keyword[if] operator[SEP] ident... |
public int[] getUnsignedPixelValues(WritableRaster raster) {
short[] pixelValues = getPixelValues(raster);
int[] unsignedPixelValues = getUnsignedPixelValues(pixelValues);
return unsignedPixelValues;
} | class class_name[name] begin[{]
method[getUnsignedPixelValues, return_type[type[int]], modifier[public], parameter[raster]] begin[{]
local_variable[type[short], pixelValues]
local_variable[type[int], unsignedPixelValues]
return[member[.unsignedPixelValues]]
end[}]
END[}] | Keyword[public] Keyword[int] operator[SEP] operator[SEP] identifier[getUnsignedPixelValues] operator[SEP] identifier[WritableRaster] identifier[raster] operator[SEP] {
Keyword[short] operator[SEP] operator[SEP] identifier[pixelValues] operator[=] identifier[getPixelValues] operator[SEP] identifier[raster] operat... |
private List<ViewApplicationActionEventPageElementDailySummary> getApplicationActionEventPageElementDailySummaryList(
final String page, final String elementId) {
final DataContainer<ViewApplicationActionEventPageElementDailySummary, ApplicationActionEventPageElementPeriodSummaryEmbeddedId> documentTypeSummaryDail... | class class_name[name] begin[{]
method[getApplicationActionEventPageElementDailySummaryList, return_type[type[List]], modifier[private], parameter[page, elementId]] begin[{]
local_variable[type[DataContainer], documentTypeSummaryDailyDataContainer]
local_variable[type[List], findOrderedListByEm... | Keyword[private] identifier[List] operator[<] identifier[ViewApplicationActionEventPageElementDailySummary] operator[>] identifier[getApplicationActionEventPageElementDailySummaryList] operator[SEP] Keyword[final] identifier[String] identifier[page] , Keyword[final] identifier[String] identifier[elementId] operator[SE... |
private boolean isIncluded(String _fqcn) {
if (includePackageNames.contains(_fqcn)) {
return true;
}
String packageName = _fqcn.substring(0, _fqcn.lastIndexOf('.') + 1);
for (String str : includePackageNames) {
if (packageName.startsWith(str)) {
r... | class class_name[name] begin[{]
method[isIncluded, return_type[type[boolean]], modifier[private], parameter[_fqcn]] begin[{]
if[call[includePackageNames.contains, parameter[member[._fqcn]]]] begin[{]
return[literal[true]]
else begin[{]
None
end[}]
local_varia... | Keyword[private] Keyword[boolean] identifier[isIncluded] operator[SEP] identifier[String] identifier[_fqcn] operator[SEP] {
Keyword[if] operator[SEP] identifier[includePackageNames] operator[SEP] identifier[contains] operator[SEP] identifier[_fqcn] operator[SEP] operator[SEP] {
Keyword[return] literal... |
public static Optional<Scheme> tryParse(@Nullable String scheme) {
if (scheme == null) {
return Optional.empty();
}
return Optional.ofNullable(SCHEMES.get(Ascii.toLowerCase(scheme)));
} | class class_name[name] begin[{]
method[tryParse, return_type[type[Optional]], modifier[public static], parameter[scheme]] begin[{]
if[binary_operation[member[.scheme], ==, literal[null]]] begin[{]
return[call[Optional.empty, parameter[]]]
else begin[{]
None
end[}]
... | Keyword[public] Keyword[static] identifier[Optional] operator[<] identifier[Scheme] operator[>] identifier[tryParse] operator[SEP] annotation[@] identifier[Nullable] identifier[String] identifier[scheme] operator[SEP] {
Keyword[if] operator[SEP] identifier[scheme] operator[==] Other[null] operator[SEP] {
... |
private URIBuilder addFieldsParam(URIBuilder builder, Class<? extends BaseResource> type, Collection<? extends Field> fields) {
List<String> fieldNames = new ArrayList<>();
for (Field f : fields) {
fieldNames.add(f.getPropertyName());
}
String typeStr = BaseResource.getType(type);
builder.addP... | class class_name[name] begin[{]
method[addFieldsParam, return_type[type[URIBuilder]], modifier[private], parameter[builder, type, fields]] begin[{]
local_variable[type[List], fieldNames]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arg... | Keyword[private] identifier[URIBuilder] identifier[addFieldsParam] operator[SEP] identifier[URIBuilder] identifier[builder] , identifier[Class] operator[<] operator[?] Keyword[extends] identifier[BaseResource] operator[>] identifier[type] , identifier[Collection] operator[<] operator[?] Keyword[extends] identifier[Fi... |
public final void increaseReadBytes(long increment, long currentTime) {
if (increment <= 0) {
return;
}
readBytes += increment;
lastReadTime = currentTime;
idleCountForBoth.set(0);
idleCountForRead.set(0);
// if (getService() instanceof AbstractIoServ... | class class_name[name] begin[{]
method[increaseReadBytes, return_type[void], modifier[final public], parameter[increment, currentTime]] begin[{]
if[binary_operation[member[.increment], <=, literal[0]]] begin[{]
return[None]
else begin[{]
None
end[}]
a... | Keyword[public] Keyword[final] Keyword[void] identifier[increaseReadBytes] operator[SEP] Keyword[long] identifier[increment] , Keyword[long] identifier[currentTime] operator[SEP] {
Keyword[if] operator[SEP] identifier[increment] operator[<=] Other[0] operator[SEP] {
Keyword[return] operator[SEP]
... |
public static <T> Set<T> modes(Collection<T> values) {
Counter<T> counter = new ClassicCounter<T>(values);
List<Double> sortedCounts = CollectionUtils.sorted(counter.values());
Double highestCount = sortedCounts.get(sortedCounts.size() - 1);
Counters.retainAbove(counter, highestCount);
return c... | class class_name[name] begin[{]
method[modes, return_type[type[Set]], modifier[public static], parameter[values]] begin[{]
local_variable[type[Counter], counter]
local_variable[type[List], sortedCounts]
local_variable[type[Double], highestCount]
call[Counters.retainAbove... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[Set] operator[<] identifier[T] operator[>] identifier[modes] operator[SEP] identifier[Collection] operator[<] identifier[T] operator[>] identifier[values] operator[SEP] {
identifier[Counter] operator[<] identifier[T] operator[>] ide... |
private static void setContentTypeHeader(HttpResponse response, File file) {
String contentType = StringKit.mimeType(file.getName());
if (null == contentType) {
contentType = URLConnection.guessContentTypeFromName(file.getName());
}
response.headers().set(HttpConst.CONTENT_TY... | class class_name[name] begin[{]
method[setContentTypeHeader, return_type[void], modifier[private static], parameter[response, file]] begin[{]
local_variable[type[String], contentType]
if[binary_operation[literal[null], ==, member[.contentType]]] begin[{]
assign[m... | Keyword[private] Keyword[static] Keyword[void] identifier[setContentTypeHeader] operator[SEP] identifier[HttpResponse] identifier[response] , identifier[File] identifier[file] operator[SEP] {
identifier[String] identifier[contentType] operator[=] identifier[StringKit] operator[SEP] identifier[mimeType] operator... |
void validateStopCloseForMessageListener(String functionCall) throws IllegalStateException {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
SibTr.entry(this, tc, "validateStopForMessageListener");
//Before triggering onMessage .. SIB pushes "owning session object" to Threa... | class class_name[name] begin[{]
method[validateStopCloseForMessageListener, return_type[void], modifier[default], parameter[functionCall]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{]
call[Sib... | Keyword[void] identifier[validateStopCloseForMessageListener] operator[SEP] identifier[String] identifier[functionCall] operator[SEP] Keyword[throws] identifier[IllegalStateException] {
Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] ... |
@Override
protected RemoteAppenderClient createClient(String id, Socket socket)
throws IOException {
return new RemoteAppenderStreamClient(id, socket);
} | class class_name[name] begin[{]
method[createClient, return_type[type[RemoteAppenderClient]], modifier[protected], parameter[id, socket]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=id, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(member=socke... | annotation[@] identifier[Override] Keyword[protected] identifier[RemoteAppenderClient] identifier[createClient] operator[SEP] identifier[String] identifier[id] , identifier[Socket] identifier[socket] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] Keyword[new] identifier[RemoteAppenderSt... |
public Datatype.Builder addAllValueTypeAnnotations(Spliterator<? extends Excerpt> elements) {
if ((elements.characteristics() & Spliterator.SIZED) != 0) {
long elementsSize = elements.estimateSize();
if (elementsSize > 0 && elementsSize <= Integer.MAX_VALUE) {
if (valueTypeAnnotations instanceof... | class class_name[name] begin[{]
method[addAllValueTypeAnnotations, return_type[type[Datatype]], modifier[public], parameter[elements]] begin[{]
if[binary_operation[binary_operation[call[elements.characteristics, parameter[]], &, member[Spliterator.SIZED]], !=, literal[0]]] begin[{]
... | Keyword[public] identifier[Datatype] operator[SEP] identifier[Builder] identifier[addAllValueTypeAnnotations] operator[SEP] identifier[Spliterator] operator[<] operator[?] Keyword[extends] identifier[Excerpt] operator[>] identifier[elements] operator[SEP] {
Keyword[if] operator[SEP] operator[SEP] identifier[elem... |
static Scenario scenario(String text) {
reset();
final Scenario scenario = new Scenario(text);
sRoot = scenario;
return scenario;
} | class class_name[name] begin[{]
method[scenario, return_type[type[Scenario]], modifier[static], parameter[text]] begin[{]
call[.reset, parameter[]]
local_variable[type[Scenario], scenario]
assign[member[.sRoot], member[.scenario]]
return[member[.scenario]]
en... | Keyword[static] identifier[Scenario] identifier[scenario] operator[SEP] identifier[String] identifier[text] operator[SEP] {
identifier[reset] operator[SEP] operator[SEP] operator[SEP] Keyword[final] identifier[Scenario] identifier[scenario] operator[=] Keyword[new] identifier[Scenario] operator[SEP] identifier[t... |
public static Slice currentTokenAsVarchar(JsonParser parser)
throws IOException
{
switch (parser.currentToken()) {
case VALUE_NULL:
return null;
case VALUE_STRING:
case FIELD_NAME:
return Slices.utf8Slice(parser.getText());
... | class class_name[name] begin[{]
method[currentTokenAsVarchar, return_type[type[Slice]], modifier[public static], parameter[parser]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=['VALUE_NULL'], statements=[ReturnStatement(expression=Literal(postfix_operators=[], prefix_operators=[], qualifie... | Keyword[public] Keyword[static] identifier[Slice] identifier[currentTokenAsVarchar] operator[SEP] identifier[JsonParser] identifier[parser] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[switch] operator[SEP] identifier[parser] operator[SEP] identifier[currentToken] operator[SEP] operator[SEP] o... |
@Override
public JSONObject toJSON() throws JSONException {
JSONObject json = super.toJSON();
JSONArray features = new JSONArray();
for (Feature feature : this.mFeatures) {
features.put(feature.toJSON());
}
json.put(JSON_FEATURES, features);
return json... | class class_name[name] begin[{]
method[toJSON, return_type[type[JSONObject]], modifier[public], parameter[]] begin[{]
local_variable[type[JSONObject], json]
local_variable[type[JSONArray], features]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=... | annotation[@] identifier[Override] Keyword[public] identifier[JSONObject] identifier[toJSON] operator[SEP] operator[SEP] Keyword[throws] identifier[JSONException] {
identifier[JSONObject] identifier[json] operator[=] Keyword[super] operator[SEP] identifier[toJSON] operator[SEP] operator[SEP] operator[SEP] identi... |
public void marshall(GetStagesRequest getStagesRequest, ProtocolMarshaller protocolMarshaller) {
if (getStagesRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(getStagesRequest.getRestApiId()... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[getStagesRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.getStagesRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postf... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[GetStagesRequest] identifier[getStagesRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[getStagesRequest] operator[==] Other[null] operator[SEP] {
Ke... |
public void assertSubscriptions() {
for (String channel : subscribers.keySet()) {
try {
subscribers.put(channel, null);
subscribe(channel);
} catch (Throwable e) {
break;
}
}
} | class class_name[name] begin[{]
method[assertSubscriptions, return_type[void], modifier[public], parameter[]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=channel, postfix_operator... | Keyword[public] Keyword[void] identifier[assertSubscriptions] operator[SEP] operator[SEP] {
Keyword[for] operator[SEP] identifier[String] identifier[channel] operator[:] identifier[subscribers] operator[SEP] identifier[keySet] operator[SEP] operator[SEP] operator[SEP] {
Keyword[try] {
... |
public void marshall(WorkflowTypeInfo workflowTypeInfo, ProtocolMarshaller protocolMarshaller) {
if (workflowTypeInfo == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(workflowTypeInfo.getWorkflowTyp... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[workflowTypeInfo, protocolMarshaller]] begin[{]
if[binary_operation[member[.workflowTypeInfo], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postf... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[WorkflowTypeInfo] identifier[workflowTypeInfo] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[workflowTypeInfo] operator[==] Other[null] operator[SEP] {
Ke... |
private int getOdoValue(String dependingOn) {
Object odoValue = variables.get(dependingOn);
if (odoValue == null) {
return 0;
} else if (odoValue instanceof Number) {
return ((Number) odoValue).intValue();
} else {
throw new CobolODOResolutionException... | class class_name[name] begin[{]
method[getOdoValue, return_type[type[int]], modifier[private], parameter[dependingOn]] begin[{]
local_variable[type[Object], odoValue]
if[binary_operation[member[.odoValue], ==, literal[null]]] begin[{]
return[literal[0]]
else begin[{]... | Keyword[private] Keyword[int] identifier[getOdoValue] operator[SEP] identifier[String] identifier[dependingOn] operator[SEP] {
identifier[Object] identifier[odoValue] operator[=] identifier[variables] operator[SEP] identifier[get] operator[SEP] identifier[dependingOn] operator[SEP] operator[SEP] Keyword[if] oper... |
public void removeTarget(T target) {
Iterator<Pattern<T>> it = patterns.iterator();
while (it.hasNext()) {
Pattern<T> pattern = it.next();
if (pattern.target().equals(target)) it.remove();
}
reverse.remove(target);
} | class class_name[name] begin[{]
method[removeTarget, return_type[void], modifier[public], parameter[target]] begin[{]
local_variable[type[Iterator], it]
while[call[it.hasNext, parameter[]]] begin[{]
local_variable[type[Pattern], pattern]
if[call[patte... | Keyword[public] Keyword[void] identifier[removeTarget] operator[SEP] identifier[T] identifier[target] operator[SEP] {
identifier[Iterator] operator[<] identifier[Pattern] operator[<] identifier[T] operator[>] operator[>] identifier[it] operator[=] identifier[patterns] operator[SEP] identifier[iterator] operator[... |
public void put(final String pattern, final V value) throws IllegalStateException {
if (pattern != null) {
if (keys.containsKey(pattern)) {
throw new IllegalStateException("");
}
keys.put(pattern, value);
final Pattern p = Pattern.compile(pattern... | class class_name[name] begin[{]
method[put, return_type[void], modifier[public], parameter[pattern, value]] begin[{]
if[binary_operation[member[.pattern], !=, literal[null]]] begin[{]
if[call[keys.containsKey, parameter[member[.pattern]]]] begin[{]
ThrowS... | Keyword[public] Keyword[void] identifier[put] operator[SEP] Keyword[final] identifier[String] identifier[pattern] , Keyword[final] identifier[V] identifier[value] operator[SEP] Keyword[throws] identifier[IllegalStateException] {
Keyword[if] operator[SEP] identifier[pattern] operator[!=] Other[null] operator[SEP... |
public static MemberExistsResult fieldExists(String fieldName, JavacNode node) {
node = upToTypeNode(node);
if (node != null && node.get() instanceof JCClassDecl) {
for (JCTree def : ((JCClassDecl)node.get()).defs) {
if (def instanceof JCVariableDecl) {
if (((JCVariableDecl)def).name.contentEquals(fi... | class class_name[name] begin[{]
method[fieldExists, return_type[type[MemberExistsResult]], modifier[public static], parameter[fieldName, node]] begin[{]
assign[member[.node], call[.upToTypeNode, parameter[member[.node]]]]
if[binary_operation[binary_operation[member[.node], !=, l... | Keyword[public] Keyword[static] identifier[MemberExistsResult] identifier[fieldExists] operator[SEP] identifier[String] identifier[fieldName] , identifier[JavacNode] identifier[node] operator[SEP] {
identifier[node] operator[=] identifier[upToTypeNode] operator[SEP] identifier[node] operator[SEP] operator[SEP] ... |
public alluxio.proto.dataserver.Protocol.OpenUfsBlockOptions getOpenUfsBlockOptions() {
return openUfsBlockOptions_ == null ? alluxio.proto.dataserver.Protocol.OpenUfsBlockOptions.getDefaultInstance() : openUfsBlockOptions_;
} | class class_name[name] begin[{]
method[getOpenUfsBlockOptions, return_type[type[alluxio]], modifier[public], parameter[]] begin[{]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=openUfsBlockOptions_, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]... | Keyword[public] identifier[alluxio] operator[SEP] identifier[proto] operator[SEP] identifier[dataserver] operator[SEP] identifier[Protocol] operator[SEP] identifier[OpenUfsBlockOptions] identifier[getOpenUfsBlockOptions] operator[SEP] operator[SEP] {
Keyword[return] identifier[openUfsBlockOptions_] operator[==] ... |
public void marshall(PutLoggingOptionsRequest putLoggingOptionsRequest, ProtocolMarshaller protocolMarshaller) {
if (putLoggingOptionsRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(putLogg... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[putLoggingOptionsRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.putLoggingOptionsRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(argument... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[PutLoggingOptionsRequest] identifier[putLoggingOptionsRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[putLoggingOptionsRequest] operator[==] Other[null] opera... |
public static FloatMatrix ger(float alpha, FloatMatrix x,
FloatMatrix y, FloatMatrix a) {
NativeBlas.sger(a.rows, a.columns, alpha, x.data, 0, 1, y.data, 0, 1, a.data,
0, a.rows);
return a;
} | class class_name[name] begin[{]
method[ger, return_type[type[FloatMatrix]], modifier[public static], parameter[alpha, x, y, a]] begin[{]
call[NativeBlas.sger, parameter[member[a.rows], member[a.columns], member[.alpha], member[x.data], literal[0], literal[1], member[y.data], literal[0], literal... | Keyword[public] Keyword[static] identifier[FloatMatrix] identifier[ger] operator[SEP] Keyword[float] identifier[alpha] , identifier[FloatMatrix] identifier[x] , identifier[FloatMatrix] identifier[y] , identifier[FloatMatrix] identifier[a] operator[SEP] {
identifier[NativeBlas] operator[SEP] identifier[sger] o... |
@Override
public <T extends GedObject> T find(
final FinderObject owner, final String str, final Class<T> clazz) {
return clazz.cast(owner.find(str));
} | class class_name[name] begin[{]
method[find, return_type[type[T]], modifier[public], parameter[owner, str, clazz]] begin[{]
return[call[clazz.cast, parameter[call[owner.find, parameter[member[.str]]]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[GedObject] operator[>] identifier[T] identifier[find] operator[SEP] Keyword[final] identifier[FinderObject] identifier[owner] , Keyword[final] identifier[String] identifier[str] , Keyword[final] identifier[Class] ... |
public TypeToken<?> parse(String string) throws ParserException {
Parser.Reference<Type> ref = Parser.newReference();
Parser<Type> type = Parsers.or(
wildcardType(ref.lazy()), parameterizedType(ref.lazy()), arrayClass(), rawType());
ref.set(type.postfix(TERMS.phrase("[", "]").retn(Types::newArrayTyp... | class class_name[name] begin[{]
method[parse, return_type[type[TypeToken]], modifier[public], parameter[string]] begin[{]
local_variable[type[Parser], ref]
local_variable[type[Parser], type]
call[ref.set, parameter[call[type.postfix, parameter[call[TERMS.phrase, parameter[litera... | Keyword[public] identifier[TypeToken] operator[<] operator[?] operator[>] identifier[parse] operator[SEP] identifier[String] identifier[string] operator[SEP] Keyword[throws] identifier[ParserException] {
identifier[Parser] operator[SEP] identifier[Reference] operator[<] identifier[Type] operator[>] identifier[re... |
public static void validateArgument(Method method, Class<? extends Annotation> annotationType,
Class<?> expectedParameterType) {
if (method.getParameterTypes().length != 1 || !method.getParameterTypes()[0].equals(expectedParameterType)) {
throw new BeanCreatio... | class class_name[name] begin[{]
method[validateArgument, return_type[void], modifier[public static], parameter[method, annotationType, expectedParameterType]] begin[{]
if[binary_operation[binary_operation[call[method.getParameterTypes, parameter[]], !=, literal[1]], ||, call[method.getParameter... | Keyword[public] Keyword[static] Keyword[void] identifier[validateArgument] operator[SEP] identifier[Method] identifier[method] , identifier[Class] operator[<] operator[?] Keyword[extends] identifier[Annotation] operator[>] identifier[annotationType] , identifier[Class] operator[<] operator[?] operator[>] identifier[e... |
public boolean generateAndSort(final Iterator<long[]> iterator, final long seed) {
// We cache all variables for faster access
final int[] d = this.d;
final int[] e = new int[3];
cleanUpIfNecessary();
/* We build the XOR'd edge list and compute the degree of each vertex. */
for(int k = 0; k < numEdges; k++... | class class_name[name] begin[{]
method[generateAndSort, return_type[type[boolean]], modifier[public], parameter[iterator, seed]] begin[{]
local_variable[type[int], d]
local_variable[type[int], e]
call[.cleanUpIfNecessary, parameter[]]
ForStatement(body=BlockStatement(lab... | Keyword[public] Keyword[boolean] identifier[generateAndSort] operator[SEP] Keyword[final] identifier[Iterator] operator[<] Keyword[long] operator[SEP] operator[SEP] operator[>] identifier[iterator] , Keyword[final] Keyword[long] identifier[seed] operator[SEP] {
Keyword[final] Keyword[int] operator[SEP] operator... |
@Override
public ShardedRedisCounter setCounterFactory(AbstractCounterFactory counterFactory) {
if (counterFactory instanceof ShardedRedisCounterFactory) {
super.setCounterFactory(counterFactory);
} else {
throw new IllegalArgumentException("Argument must be an instance of "
... | class class_name[name] begin[{]
method[setCounterFactory, return_type[type[ShardedRedisCounter]], modifier[public], parameter[counterFactory]] begin[{]
if[binary_operation[member[.counterFactory], instanceof, type[ShardedRedisCounterFactory]]] begin[{]
SuperMethodInvocat... | annotation[@] identifier[Override] Keyword[public] identifier[ShardedRedisCounter] identifier[setCounterFactory] operator[SEP] identifier[AbstractCounterFactory] identifier[counterFactory] operator[SEP] {
Keyword[if] operator[SEP] identifier[counterFactory] Keyword[instanceof] identifier[ShardedRedisCounterFacto... |
public Result<List<StraightPathItem>> findStraightPath(float[] startPos, float[] endPos, List<Long> path,
int maxStraightPath, int options) {
List<StraightPathItem> straightPath = new ArrayList<>();
if (Objects.isNull(startPos) || !vIsFinite(startPos) || Objects.isNull(endPos) || !vIsFinite... | class class_name[name] begin[{]
method[findStraightPath, return_type[type[Result]], modifier[public], parameter[startPos, endPos, path, maxStraightPath, options]] begin[{]
local_variable[type[List], straightPath]
if[binary_operation[binary_operation[binary_operation[binary_operation[bin... | Keyword[public] identifier[Result] operator[<] identifier[List] operator[<] identifier[StraightPathItem] operator[>] operator[>] identifier[findStraightPath] operator[SEP] Keyword[float] operator[SEP] operator[SEP] identifier[startPos] , Keyword[float] operator[SEP] operator[SEP] identifier[endPos] , identifier[List]... |
@Override
public Validation validate(Context context, String pid,
Date asOfDateTime) throws ServerException {
return mgmt.validate(context, pid, asOfDateTime);
} | class class_name[name] begin[{]
method[validate, return_type[type[Validation]], modifier[public], parameter[context, pid, asOfDateTime]] begin[{]
return[call[mgmt.validate, parameter[member[.context], member[.pid], member[.asOfDateTime]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] identifier[Validation] identifier[validate] operator[SEP] identifier[Context] identifier[context] , identifier[String] identifier[pid] , identifier[Date] identifier[asOfDateTime] operator[SEP] Keyword[throws] identifier[ServerException] {
Keyword[return] ident... |
public void stop(String logicalQueueName) {
stopQueue(logicalQueueName);
try {
if (isRunning(logicalQueueName)) {
Future<?> future = this.scheduledFutureByQueue.remove(logicalQueueName);
if (future != null) {
future.get(this.queueStopTimeout, TimeUnit.MILLISECONDS);
}
}
}
catch (Interrup... | class class_name[name] begin[{]
method[stop, return_type[void], modifier[public], parameter[logicalQueueName]] begin[{]
call[.stopQueue, parameter[member[.logicalQueueName]]]
TryStatement(block=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=logicalQueueName, p... | Keyword[public] Keyword[void] identifier[stop] operator[SEP] identifier[String] identifier[logicalQueueName] operator[SEP] {
identifier[stopQueue] operator[SEP] identifier[logicalQueueName] operator[SEP] operator[SEP] Keyword[try] {
Keyword[if] operator[SEP] identifier[isRunning] operator[SEP] identif... |
public static SampleDialogFragment newInstance(int radius,
float downScaleFactor,
boolean dimming,
boolean debug) {
SampleDialogFragment fragment = new SampleD... | class class_name[name] begin[{]
method[newInstance, return_type[type[SampleDialogFragment]], modifier[public static], parameter[radius, downScaleFactor, dimming, debug]] begin[{]
local_variable[type[SampleDialogFragment], fragment]
local_variable[type[Bundle], args]
call[args.pu... | Keyword[public] Keyword[static] identifier[SampleDialogFragment] identifier[newInstance] operator[SEP] Keyword[int] identifier[radius] , Keyword[float] identifier[downScaleFactor] , Keyword[boolean] identifier[dimming] , Keyword[boolean] identifier[debug] operator[SEP] {
identifier[SampleDialogFragment] ident... |
@Override
public boolean publishAll(boolean dryDeploy) {
return stages.publishAll(dryDeploy, (progress, maxProgress) -> context.broadcast(Orchid.Lifecycle.ProgressEvent.fire(this, "deploying", progress, maxProgress)));
} | class class_name[name] begin[{]
method[publishAll, return_type[type[boolean]], modifier[public], parameter[dryDeploy]] begin[{]
return[call[stages.publishAll, parameter[member[.dryDeploy], LambdaExpression(body=MethodInvocation(arguments=[MethodInvocation(arguments=[This(postfix_operators=[], prefix_op... | annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[publishAll] operator[SEP] Keyword[boolean] identifier[dryDeploy] operator[SEP] {
Keyword[return] identifier[stages] operator[SEP] identifier[publishAll] operator[SEP] identifier[dryDeploy] , operator[SEP] identifier[progress] , iden... |
public static ReasonerQueryImpl create(Conjunction<Statement> pattern, TransactionOLTP tx) {
ReasonerQueryImpl query = new ReasonerQueryImpl(pattern, tx).inferTypes();
return query.isAtomic()?
new ReasonerAtomicQuery(query.getAtoms(), tx) :
query;
} | class class_name[name] begin[{]
method[create, return_type[type[ReasonerQueryImpl]], modifier[public static], parameter[pattern, tx]] begin[{]
local_variable[type[ReasonerQueryImpl], query]
return[TernaryExpression(condition=MethodInvocation(arguments=[], member=isAtomic, postfix_operators=[], ... | Keyword[public] Keyword[static] identifier[ReasonerQueryImpl] identifier[create] operator[SEP] identifier[Conjunction] operator[<] identifier[Statement] operator[>] identifier[pattern] , identifier[TransactionOLTP] identifier[tx] operator[SEP] {
identifier[ReasonerQueryImpl] identifier[query] operator[=] Keywor... |
public static void compute(List<Vertex> vertexList, TransformMatrix transformMatrixDictionary)
{
if (Nature.values().length != transformMatrixDictionary.states.length)
transformMatrixDictionary.extend(Nature.values().length);
int length = vertexList.size() - 1;
double[][] cost = ... | class class_name[name] begin[{]
method[compute, return_type[void], modifier[public static], parameter[vertexList, transformMatrixDictionary]] begin[{]
if[binary_operation[call[Nature.values, parameter[]], !=, member[transformMatrixDictionary.states.length]]] begin[{]
call[transformM... | Keyword[public] Keyword[static] Keyword[void] identifier[compute] operator[SEP] identifier[List] operator[<] identifier[Vertex] operator[>] identifier[vertexList] , identifier[TransformMatrix] identifier[transformMatrixDictionary] operator[SEP] {
Keyword[if] operator[SEP] identifier[Nature] operator[SEP] identi... |
public static INDArray eq(INDArray x, INDArray y, INDArray z, int... dimensions) {
if(dimensions == null || dimensions.length == 0) {
validateShapesNoDimCase(x,y,z);
return Nd4j.getExecutioner().exec(new OldEqualTo(x,y,z));
}
return Nd4j.getExecutioner().exec(new Broadcas... | class class_name[name] begin[{]
method[eq, return_type[type[INDArray]], modifier[public static], parameter[x, y, z, dimensions]] begin[{]
if[binary_operation[binary_operation[member[.dimensions], ==, literal[null]], ||, binary_operation[member[dimensions.length], ==, literal[0]]]] begin[{]
... | Keyword[public] Keyword[static] identifier[INDArray] identifier[eq] operator[SEP] identifier[INDArray] identifier[x] , identifier[INDArray] identifier[y] , identifier[INDArray] identifier[z] , Keyword[int] operator[...] identifier[dimensions] operator[SEP] {
Keyword[if] operator[SEP] identifier[dimensions] op... |
@Override
public void addPackageDescription(Content packageContentTree) {
if (!utils.getBody(packageElement).isEmpty()) {
Content tree = configuration.allowTag(HtmlTag.SECTION) ? sectionTree : packageContentTree;
addDeprecationInfo(tree);
addInlineComment(packageElement, ... | class class_name[name] begin[{]
method[addPackageDescription, return_type[void], modifier[public], parameter[packageContentTree]] begin[{]
if[call[utils.getBody, parameter[member[.packageElement]]]] begin[{]
local_variable[type[Content], tree]
call[.addDeprec... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[addPackageDescription] operator[SEP] identifier[Content] identifier[packageContentTree] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[utils] operator[SEP] identifier[getBody] operator[SEP] identifier[packageElement] op... |
public void addStructural(E entry) {
if (entry.getNext() != null)
throw new IllegalArgumentException(
"The given entry should be fresh!");
int h = entry.structuralHashCode();
int i = indexFor(h, buckets.length);
modCount++;
E e = buckets[i];
entry.setNext(e);
buckets[i] = entry;
if (size++ >= ov... | class class_name[name] begin[{]
method[addStructural, return_type[void], modifier[public], parameter[entry]] begin[{]
if[binary_operation[call[entry.getNext, parameter[]], !=, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operato... | Keyword[public] Keyword[void] identifier[addStructural] operator[SEP] identifier[E] identifier[entry] operator[SEP] {
Keyword[if] operator[SEP] identifier[entry] operator[SEP] identifier[getNext] operator[SEP] operator[SEP] operator[!=] Other[null] operator[SEP] Keyword[throw] Keyword[new] identifier[IllegalArgu... |
public static ConditionBuilder isCommitted()
{
return new HttpCondition() {
@Override
public boolean evaluateHttp(HttpServletRewrite event, EvaluationContext context)
{
return event.getResponse().isCommitted();
}
@Override
public String toStrin... | class class_name[name] begin[{]
method[isCommitted, return_type[type[ConditionBuilder]], modifier[public static], parameter[]] begin[{]
return[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[ReturnStatement(expression=MethodInvocation(argu... | Keyword[public] Keyword[static] identifier[ConditionBuilder] identifier[isCommitted] operator[SEP] operator[SEP] {
Keyword[return] Keyword[new] identifier[HttpCondition] operator[SEP] operator[SEP] {
annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[evaluateHttp] operator[... |
public void sortXml() {
newDocument = (Document) originalDocument.clone();
final Element rootElement = (Element) originalDocument.getRootElement().clone();
HierarchyRootWrapper rootWrapper = factory.createFromRootElement(rootElement);
rootWrapper.createWrappedStructure(factory);
... | class class_name[name] begin[{]
method[sortXml, return_type[void], modifier[public], parameter[]] begin[{]
assign[member[.newDocument], Cast(expression=MethodInvocation(arguments=[], member=clone, postfix_operators=[], prefix_operators=[], qualifier=originalDocument, selectors=[], type_argument... | Keyword[public] Keyword[void] identifier[sortXml] operator[SEP] operator[SEP] {
identifier[newDocument] operator[=] operator[SEP] identifier[Document] operator[SEP] identifier[originalDocument] operator[SEP] identifier[clone] operator[SEP] operator[SEP] operator[SEP] Keyword[final] identifier[Element] identifier... |
public static void getDeclaredFields(Class c, Collection<Field> fields) {
try
{
Field[] local = c.getDeclaredFields();
for (Field field : local)
{
if (!field.isAccessible())
{
try
{
... | class class_name[name] begin[{]
method[getDeclaredFields, return_type[void], modifier[public static], parameter[c, fields]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[], member=getDeclaredF... | Keyword[public] Keyword[static] Keyword[void] identifier[getDeclaredFields] operator[SEP] identifier[Class] identifier[c] , identifier[Collection] operator[<] identifier[Field] operator[>] identifier[fields] operator[SEP] {
Keyword[try] {
identifier[Field] operator[SEP] operator[SEP] identifier[local... |
public <S extends Service> S getService(Class<S> type) {
for (final Service serv : this.serviceManager.servicesByState().values()) {
if (serv.isRunning() && type.isInstance(serv)) {
return type.cast(serv);
}
}
return null;
} | class class_name[name] begin[{]
method[getService, return_type[type[S]], modifier[public], parameter[type]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MethodInvocation(arguments=[], member=isRunning, postfix_operators=[], prefix_oper... | Keyword[public] operator[<] identifier[S] Keyword[extends] identifier[Service] operator[>] identifier[S] identifier[getService] operator[SEP] identifier[Class] operator[<] identifier[S] operator[>] identifier[type] operator[SEP] {
Keyword[for] operator[SEP] Keyword[final] identifier[Service] identifier[serv] ope... |
public T get(String key) throws Exception {
CacheEntry<T> entry = this.objects.get(key);
return entry != null ? entry.getUpToDateObject() : null;
} | class class_name[name] begin[{]
method[get, return_type[type[T]], modifier[public], parameter[key]] begin[{]
local_variable[type[CacheEntry], entry]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=entry, postfix_operators=[], prefix_operators=[], qualifier=, s... | Keyword[public] identifier[T] identifier[get] operator[SEP] identifier[String] identifier[key] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[CacheEntry] operator[<] identifier[T] operator[>] identifier[entry] operator[=] Keyword[this] operator[SEP] identifier[objects] operator[SEP] identifier[... |
protected void computeClusterDistance() {
for( int i = 0; i < pixels.size; i++ ) {
pixels.data[i].reset();
}
for( int i = 0; i < clusters.size && !stopRequested; i++ ) {
Cluster c = clusters.data[i];
// compute search bounds
int centerX = (int)(c.x + 0.5f);
int centerY = (int)(c.y + 0.5f);
in... | class class_name[name] begin[{]
method[computeClusterDistance, return_type[void], modifier[protected], parameter[]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MemberReference(member=data, postfix_operators=[], prefix_operators=[], qualifier=pixels, ... | Keyword[protected] Keyword[void] identifier[computeClusterDistance] operator[SEP] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] identifier[pixels] operator[SEP] identifier[size] operator[SEP] identifier[i] operator[++] operator[... |
public NodeType[] getRequiredPrimaryTypes()
{
InternalQName[] requiredPrimaryTypes = nodeDefinitionData.getRequiredPrimaryTypes();
NodeType[] result = new NodeType[requiredPrimaryTypes.length];
for (int i = 0; i < requiredPrimaryTypes.length; i++)
{
NodeTypeData ntData = nodeTypeData... | class class_name[name] begin[{]
method[getRequiredPrimaryTypes, return_type[type[NodeType]], modifier[public], parameter[]] begin[{]
local_variable[type[InternalQName], requiredPrimaryTypes]
local_variable[type[NodeType], result]
ForStatement(body=BlockStatement(label=None, statements=[... | Keyword[public] identifier[NodeType] operator[SEP] operator[SEP] identifier[getRequiredPrimaryTypes] operator[SEP] operator[SEP] {
identifier[InternalQName] operator[SEP] operator[SEP] identifier[requiredPrimaryTypes] operator[=] identifier[nodeDefinitionData] operator[SEP] identifier[getRequiredPrimaryTypes] op... |
public Bucket reload() {
// [START reload]
Bucket latestBucket = bucket.reload(BucketSourceOption.metagenerationMatch());
if (latestBucket == null) {
// the bucket was not found
}
// [END reload]
return latestBucket;
} | class class_name[name] begin[{]
method[reload, return_type[type[Bucket]], modifier[public], parameter[]] begin[{]
local_variable[type[Bucket], latestBucket]
if[binary_operation[member[.latestBucket], ==, literal[null]]] begin[{]
else begin[{]
None
end[}]
return[... | Keyword[public] identifier[Bucket] identifier[reload] operator[SEP] operator[SEP] {
identifier[Bucket] identifier[latestBucket] operator[=] identifier[bucket] operator[SEP] identifier[reload] operator[SEP] identifier[BucketSourceOption] operator[SEP] identifier[metagenerationMatch] operator[SEP] operator[SEP] op... |
public IfcHumidifierTypeEnum createIfcHumidifierTypeEnumFromString(EDataType eDataType, String initialValue) {
IfcHumidifierTypeEnum result = IfcHumidifierTypeEnum.get(initialValue);
if (result == null)
throw new IllegalArgumentException(
"The value '" + initialValue + "' is not a valid enumerator of '"... | class class_name[name] begin[{]
method[createIfcHumidifierTypeEnumFromString, return_type[type[IfcHumidifierTypeEnum]], modifier[public], parameter[eDataType, initialValue]] begin[{]
local_variable[type[IfcHumidifierTypeEnum], result]
if[binary_operation[member[.result], ==, literal[nul... | Keyword[public] identifier[IfcHumidifierTypeEnum] identifier[createIfcHumidifierTypeEnumFromString] operator[SEP] identifier[EDataType] identifier[eDataType] , identifier[String] identifier[initialValue] operator[SEP] {
identifier[IfcHumidifierTypeEnum] identifier[result] operator[=] identifier[IfcHumidifierTyp... |
@Override
public List<Record> signalEndTrack(int newDepth, long timeEnded) {
List<Record> willReturn = new ArrayList<Record>();
//(get state info)
boolean trackWasNonempty = current.somethingPrinted;
//(flush)
flush(current,willReturn);
current = stack.pop();
//(update seen counts)... | class class_name[name] begin[{]
method[signalEndTrack, return_type[type[List]], modifier[public], parameter[newDepth, timeEnded]] begin[{]
local_variable[type[List], willReturn]
local_variable[type[boolean], trackWasNonempty]
call[.flush, parameter[member[.current], member[.will... | annotation[@] identifier[Override] Keyword[public] identifier[List] operator[<] identifier[Record] operator[>] identifier[signalEndTrack] operator[SEP] Keyword[int] identifier[newDepth] , Keyword[long] identifier[timeEnded] operator[SEP] {
identifier[List] operator[<] identifier[Record] operator[>] identifier[w... |
public void activateOptions() {
getLogger().info("activateOptions");
active = true;
Runnable runnable = new Runnable() {
public void run() {
initialize();
while (reader == null) {
getLogger().info("attempting to load file: " + getFileURL());
try {
... | class class_name[name] begin[{]
method[activateOptions, return_type[void], modifier[public], parameter[]] begin[{]
call[.getLogger, parameter[]]
assign[member[.active], literal[true]]
local_variable[type[Runnable], runnable]
if[member[.useCurrentThread]] ... | Keyword[public] Keyword[void] identifier[activateOptions] operator[SEP] operator[SEP] {
identifier[getLogger] operator[SEP] operator[SEP] operator[SEP] identifier[info] operator[SEP] literal[String] operator[SEP] operator[SEP] identifier[active] operator[=] literal[boolean] operator[SEP] identifier[Runnable] ide... |
@Override
public void setIsolationLevel(IsolationLevel level) throws IllegalStateException {
if(level != IsolationLevels.SNAPSHOT){
throw new IllegalStateException("Only IsolationLevels.SNAPSHOT level supported.");
}else{
super.setIsolationLevel(level);
}
} | class class_name[name] begin[{]
method[setIsolationLevel, return_type[void], modifier[public], parameter[level]] begin[{]
if[binary_operation[member[.level], !=, member[IsolationLevels.SNAPSHOT]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[setIsolationLevel] operator[SEP] identifier[IsolationLevel] identifier[level] operator[SEP] Keyword[throws] identifier[IllegalStateException] {
Keyword[if] operator[SEP] identifier[level] operator[!=] identifier[IsolationLevels] operator... |
public static final <X> Function<X,Boolean> isNullBy(final IFunction<X,?> by) {
return FnFunc.chain(by, FnObject.isNull());
} | class class_name[name] begin[{]
method[isNullBy, return_type[type[Function]], modifier[final public static], parameter[by]] begin[{]
return[call[FnFunc.chain, parameter[member[.by], call[FnObject.isNull, parameter[]]]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[final] operator[<] identifier[X] operator[>] identifier[Function] operator[<] identifier[X] , identifier[Boolean] operator[>] identifier[isNullBy] operator[SEP] Keyword[final] identifier[IFunction] operator[<] identifier[X] , operator[?] operator[>] identifier[by] operator[SEP]... |
void flush() {
internalLock.writeLock().lock();
flushLock.lock();
try {
if (isNew || modifiedBy.size() > 0) {
VanillaDb.logMgr().flush(lastLsn);
contents.write(blk);
modifiedBy.clear();
isNew = false;
}
} finally {
flushLock.unlock();
internalLock.writeLock().unlock();
... | class class_name[name] begin[{]
method[flush, return_type[void], modifier[default], parameter[]] begin[{]
call[internalLock.writeLock, parameter[]]
call[flushLock.lock, parameter[]]
TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member... | Keyword[void] identifier[flush] operator[SEP] operator[SEP] {
identifier[internalLock] operator[SEP] identifier[writeLock] operator[SEP] operator[SEP] operator[SEP] identifier[lock] operator[SEP] operator[SEP] operator[SEP] identifier[flushLock] operator[SEP] identifier[lock] operator[SEP] operator[SEP] operator... |
public Status validateResponseContent(Object responseContent, String uri, String httpMethod, String statusCode, String mediaTypeName) {
OpenApiOperation operation = null;
try {
operation = getOpenApiOperation(uri, httpMethod);
} catch (URISyntaxException e) {
logger.error... | class class_name[name] begin[{]
method[validateResponseContent, return_type[type[Status]], modifier[public], parameter[responseContent, uri, httpMethod, statusCode, mediaTypeName]] begin[{]
local_variable[type[OpenApiOperation], operation]
TryStatement(block=[StatementExpression(expression=Assi... | Keyword[public] identifier[Status] identifier[validateResponseContent] operator[SEP] identifier[Object] identifier[responseContent] , identifier[String] identifier[uri] , identifier[String] identifier[httpMethod] , identifier[String] identifier[statusCode] , identifier[String] identifier[mediaTypeName] operator[SEP... |
private Set<Alert> getSelectedAlertsImpl(boolean allAlerts) {
TreePath[] paths = getTreeAlert().getSelectionPaths();
if (paths == null || paths.length == 0) {
return Collections.emptySet();
}
Set<Alert> alerts = new HashSet<>();
if (!allAlerts) {
DefaultMutableTreeNode alertNode = (DefaultMutab... | class class_name[name] begin[{]
method[getSelectedAlertsImpl, return_type[type[Set]], modifier[private], parameter[allAlerts]] begin[{]
local_variable[type[TreePath], paths]
if[binary_operation[binary_operation[member[.paths], ==, literal[null]], ||, binary_operation[member[paths.length... | Keyword[private] identifier[Set] operator[<] identifier[Alert] operator[>] identifier[getSelectedAlertsImpl] operator[SEP] Keyword[boolean] identifier[allAlerts] operator[SEP] {
identifier[TreePath] operator[SEP] operator[SEP] identifier[paths] operator[=] identifier[getTreeAlert] operator[SEP] operator[SEP] ope... |
public Observable<ServiceResponse<SiteSealInner>> retrieveSiteSealWithServiceResponseAsync(String resourceGroupName, String certificateOrderName, SiteSealRequest siteSealRequest) {
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot... | class class_name[name] begin[{]
method[retrieveSiteSealWithServiceResponseAsync, return_type[type[Observable]], modifier[public], parameter[resourceGroupName, certificateOrderName, siteSealRequest]] begin[{]
if[binary_operation[member[.resourceGroupName], ==, literal[null]]] begin[{]
... | Keyword[public] identifier[Observable] operator[<] identifier[ServiceResponse] operator[<] identifier[SiteSealInner] operator[>] operator[>] identifier[retrieveSiteSealWithServiceResponseAsync] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[certificateOrderName] , ident... |
public static void setAtomProperties(IChemModel chemModel, Object propKey, Object propVal) {
if (chemModel.getMoleculeSet() != null) {
MoleculeSetManipulator.setAtomProperties(chemModel.getMoleculeSet(), propKey, propVal);
}
if (chemModel.getReactionSet() != null) {
React... | class class_name[name] begin[{]
method[setAtomProperties, return_type[void], modifier[public static], parameter[chemModel, propKey, propVal]] begin[{]
if[binary_operation[call[chemModel.getMoleculeSet, parameter[]], !=, literal[null]]] begin[{]
call[MoleculeSetManipulato... | Keyword[public] Keyword[static] Keyword[void] identifier[setAtomProperties] operator[SEP] identifier[IChemModel] identifier[chemModel] , identifier[Object] identifier[propKey] , identifier[Object] identifier[propVal] operator[SEP] {
Keyword[if] operator[SEP] identifier[chemModel] operator[SEP] identifier[getMo... |
private static DistributionValue.BucketOptions toBucketOptionsProto(
Distribution.BucketOptions bucketOptions) {
final DistributionValue.BucketOptions.Builder builder =
DistributionValue.BucketOptions.newBuilder();
bucketOptions.match(
new Function<Distribution.BucketOptions.ExplicitOption... | class class_name[name] begin[{]
method[toBucketOptionsProto, return_type[type[DistributionValue]], modifier[private static], parameter[bucketOptions]] begin[{]
local_variable[type[DistributionValue], builder]
call[bucketOptions.match, parameter[ClassCreator(arguments=[], body=[MethodDec... | Keyword[private] Keyword[static] identifier[DistributionValue] operator[SEP] identifier[BucketOptions] identifier[toBucketOptionsProto] operator[SEP] identifier[Distribution] operator[SEP] identifier[BucketOptions] identifier[bucketOptions] operator[SEP] {
Keyword[final] identifier[DistributionValue] operator[SE... |
@BetaApi
public final Operation setSslPolicyTargetSslProxy(
String targetSslProxy, SslPolicyReference sslPolicyReferenceResource) {
SetSslPolicyTargetSslProxyHttpRequest request =
SetSslPolicyTargetSslProxyHttpRequest.newBuilder()
.setTargetSslProxy(targetSslProxy)
.setSslPo... | class class_name[name] begin[{]
method[setSslPolicyTargetSslProxy, return_type[type[Operation]], modifier[final public], parameter[targetSslProxy, sslPolicyReferenceResource]] begin[{]
local_variable[type[SetSslPolicyTargetSslProxyHttpRequest], request]
return[call[.setSslPolicyTargetSslProxy, ... | annotation[@] identifier[BetaApi] Keyword[public] Keyword[final] identifier[Operation] identifier[setSslPolicyTargetSslProxy] operator[SEP] identifier[String] identifier[targetSslProxy] , identifier[SslPolicyReference] identifier[sslPolicyReferenceResource] operator[SEP] {
identifier[SetSslPolicyTargetSslProxyH... |
private Optional<HttpSessionToken> getDefaultToken(String name) {
return defaultTokens.stream().filter(e -> name.equalsIgnoreCase(e.getName())).findFirst();
} | class class_name[name] begin[{]
method[getDefaultToken, return_type[type[Optional]], modifier[private], parameter[name]] begin[{]
return[call[defaultTokens.stream, parameter[]]]
end[}]
END[}] | Keyword[private] identifier[Optional] operator[<] identifier[HttpSessionToken] operator[>] identifier[getDefaultToken] operator[SEP] identifier[String] identifier[name] operator[SEP] {
Keyword[return] identifier[defaultTokens] operator[SEP] identifier[stream] operator[SEP] operator[SEP] operator[SEP] identifier[... |
@Override
public HttpMessage get(int index) {
try {
return historyReferences.get(index).getHttpMessage();
} catch (HttpMalformedHeaderException | DatabaseException e) {
if (LOGGER.isDebugEnabled()) {
LOGGER.debug("Failed to get the message from DB: " + e.getMe... | class class_name[name] begin[{]
method[get, return_type[type[HttpMessage]], modifier[public], parameter[index]] begin[{]
TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[MemberReference(member=index, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], member... | annotation[@] identifier[Override] Keyword[public] identifier[HttpMessage] identifier[get] operator[SEP] Keyword[int] identifier[index] operator[SEP] {
Keyword[try] {
Keyword[return] identifier[historyReferences] operator[SEP] identifier[get] operator[SEP] identifier[index] operator[SEP] operator[SEP]... |
protected final void fireVetoableChange(String propertyName,
Object oldValue, Object newValue)
throws PropertyVetoException {
vcs.fireVetoableChange(propertyName, oldValue, newValue);
} | class class_name[name] begin[{]
method[fireVetoableChange, return_type[void], modifier[final protected], parameter[propertyName, oldValue, newValue]] begin[{]
call[vcs.fireVetoableChange, parameter[member[.propertyName], member[.oldValue], member[.newValue]]]
end[}]
END[}] | Keyword[protected] Keyword[final] Keyword[void] identifier[fireVetoableChange] operator[SEP] identifier[String] identifier[propertyName] , identifier[Object] identifier[oldValue] , identifier[Object] identifier[newValue] operator[SEP] Keyword[throws] identifier[PropertyVetoException] {
identifier[vcs] operator... |
void errorForDOM3(String msg, Object[] args) throws TransformerException
{
String fmsg = XSLMessages.createXPATHMessage(msg, args);
ErrorListener ehandler = this.getErrorListener();
TransformerException te = new XPathStylesheetDOM3Exception(fmsg, m_sourceLocator);
if (null != ehandler)
{
// TO DO: Need to g... | class class_name[name] begin[{]
method[errorForDOM3, return_type[void], modifier[default], parameter[msg, args]] begin[{]
local_variable[type[String], fmsg]
local_variable[type[ErrorListener], ehandler]
local_variable[type[TransformerException], te]
if[binary_operation[l... | Keyword[void] identifier[errorForDOM3] operator[SEP] identifier[String] identifier[msg] , identifier[Object] operator[SEP] operator[SEP] identifier[args] operator[SEP] Keyword[throws] identifier[TransformerException] {
identifier[String] identifier[fmsg] operator[=] identifier[XSLMessages] operator[SEP] identif... |
public FragmentBundlerCompat<F> putStringArrayList(String key, ArrayList<String> value) {
bundler.putStringArrayList(key, value);
return this;
} | class class_name[name] begin[{]
method[putStringArrayList, return_type[type[FragmentBundlerCompat]], modifier[public], parameter[key, value]] begin[{]
call[bundler.putStringArrayList, parameter[member[.key], member[.value]]]
return[THIS[]]
end[}]
END[}] | Keyword[public] identifier[FragmentBundlerCompat] operator[<] identifier[F] operator[>] identifier[putStringArrayList] operator[SEP] identifier[String] identifier[key] , identifier[ArrayList] operator[<] identifier[String] operator[>] identifier[value] operator[SEP] {
identifier[bundler] operator[SEP] identifie... |
private static void writeFlags(ObjectOutput out, Fieldable field) throws IOException
{
int flags = 0;
if (field.isStored())
{
flags |= STORED_FLAG;
}
if (field.isIndexed())
{
flags |= INDEXED_FLAG;
}
if (field.isTokenized())
{
flags |= ... | class class_name[name] begin[{]
method[writeFlags, return_type[void], modifier[private static], parameter[out, field]] begin[{]
local_variable[type[int], flags]
if[call[field.isStored, parameter[]]] begin[{]
assign[member[.flags], member[.STORED_FLAG]]
el... | Keyword[private] Keyword[static] Keyword[void] identifier[writeFlags] operator[SEP] identifier[ObjectOutput] identifier[out] , identifier[Fieldable] identifier[field] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[int] identifier[flags] operator[=] Other[0] operator[SEP] Keyword[if] operator[SE... |
protected AuthenticationBuilder authenticateInternal(final AuthenticationTransaction transaction) throws AuthenticationException {
val credentials = transaction.getCredentials();
LOGGER.debug("Authentication credentials provided for this transaction are [{}]", credentials);
if (credentials.isEm... | class class_name[name] begin[{]
method[authenticateInternal, return_type[type[AuthenticationBuilder]], modifier[protected], parameter[transaction]] begin[{]
local_variable[type[val], credentials]
call[LOGGER.debug, parameter[literal["Authentication credentials provided for this transact... | Keyword[protected] identifier[AuthenticationBuilder] identifier[authenticateInternal] operator[SEP] Keyword[final] identifier[AuthenticationTransaction] identifier[transaction] operator[SEP] Keyword[throws] identifier[AuthenticationException] {
identifier[val] identifier[credentials] operator[=] identifier[trans... |
public String storeExternalLink(String externalLink) {
if (!CmsStringUtil.isEmptyOrWhitespaceOnly(m_linkGallery)) {
m_externalLinks.add(externalLink);
return getExternalLinkFile(externalLink);
}
return null;
} | class class_name[name] begin[{]
method[storeExternalLink, return_type[type[String]], modifier[public], parameter[externalLink]] begin[{]
if[call[CmsStringUtil.isEmptyOrWhitespaceOnly, parameter[member[.m_linkGallery]]]] begin[{]
call[m_externalLinks.add, parameter[member... | Keyword[public] identifier[String] identifier[storeExternalLink] operator[SEP] identifier[String] identifier[externalLink] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[CmsStringUtil] operator[SEP] identifier[isEmptyOrWhitespaceOnly] operator[SEP] identifier[m_linkGallery] operator[SEP] operat... |
@Override
public IComplexNDArray mmuli(INDArray other, INDArray result) {
IComplexNDArray otherArray = (IComplexNDArray) other;
IComplexNDArray resultArray = (IComplexNDArray) result;
if (other.shape().length > 2) {
for (int i = 0; i < other.slices(); i++) {
re... | class class_name[name] begin[{]
method[mmuli, return_type[type[IComplexNDArray]], modifier[public], parameter[other, result]] begin[{]
local_variable[type[IComplexNDArray], otherArray]
local_variable[type[IComplexNDArray], resultArray]
if[binary_operation[call[other.shape, param... | annotation[@] identifier[Override] Keyword[public] identifier[IComplexNDArray] identifier[mmuli] operator[SEP] identifier[INDArray] identifier[other] , identifier[INDArray] identifier[result] operator[SEP] {
identifier[IComplexNDArray] identifier[otherArray] operator[=] operator[SEP] identifier[IComplexNDArray]... |
protected void generateRowStart(ResponseWriter writer, int row, String[] rowClasses, PanelGrid panelGrid) throws IOException {
writer.startElement("div", panelGrid);
if (null == rowClasses)
writer.writeAttribute("class", "row", "class");
else
writer.writeAttribute("class", "row " + rowClasses[row % rowClass... | class class_name[name] begin[{]
method[generateRowStart, return_type[void], modifier[protected], parameter[writer, row, rowClasses, panelGrid]] begin[{]
call[writer.startElement, parameter[literal["div"], member[.panelGrid]]]
if[binary_operation[literal[null], ==, member[.rowCla... | Keyword[protected] Keyword[void] identifier[generateRowStart] operator[SEP] identifier[ResponseWriter] identifier[writer] , Keyword[int] identifier[row] , identifier[String] operator[SEP] operator[SEP] identifier[rowClasses] , identifier[PanelGrid] identifier[panelGrid] operator[SEP] Keyword[throws] identifier[IOExc... |
public MethodHandle getStatic(MethodHandles.Lookup lookup, Class<?> target, String name) throws NoSuchFieldException, IllegalAccessException {
return invoke(lookup.findStaticGetter(target, name, type().returnType()));
} | class class_name[name] begin[{]
method[getStatic, return_type[type[MethodHandle]], modifier[public], parameter[lookup, target, name]] begin[{]
return[call[.invoke, parameter[call[lookup.findStaticGetter, parameter[member[.target], member[.name], call[.type, parameter[]]]]]]]
end[}]
END[}] | Keyword[public] identifier[MethodHandle] identifier[getStatic] operator[SEP] identifier[MethodHandles] operator[SEP] identifier[Lookup] identifier[lookup] , identifier[Class] operator[<] operator[?] operator[>] identifier[target] , identifier[String] identifier[name] operator[SEP] Keyword[throws] identifier[NoSuchFie... |
@Override
public <E> E get(Class<E> clazz, Object key)
throws ConcurrentModificationException, IndoubtException {
Key k = Keys.create(Translation.toKind(clazz), key);
unlock(k);
List<Entity> entities = null;
if ((local == null)) {
entities = datastore.query(new Query(k));
} else {
entities = data... | class class_name[name] begin[{]
method[get, return_type[type[E]], modifier[public], parameter[clazz, key]] begin[{]
local_variable[type[Key], k]
call[.unlock, parameter[member[.k]]]
local_variable[type[List], entities]
if[binary_operation[member[.local], ==, lite... | annotation[@] identifier[Override] Keyword[public] operator[<] identifier[E] operator[>] identifier[E] identifier[get] operator[SEP] identifier[Class] operator[<] identifier[E] operator[>] identifier[clazz] , identifier[Object] identifier[key] operator[SEP] Keyword[throws] identifier[ConcurrentModificationException] ,... |
public ExpressRouteCircuitAuthorizationInner beginCreateOrUpdate(String resourceGroupName, String circuitName, String authorizationName, ExpressRouteCircuitAuthorizationInner authorizationParameters) {
return beginCreateOrUpdateWithServiceResponseAsync(resourceGroupName, circuitName, authorizationName, authoriz... | class class_name[name] begin[{]
method[beginCreateOrUpdate, return_type[type[ExpressRouteCircuitAuthorizationInner]], modifier[public], parameter[resourceGroupName, circuitName, authorizationName, authorizationParameters]] begin[{]
return[call[.beginCreateOrUpdateWithServiceResponseAsync, parameter[mem... | Keyword[public] identifier[ExpressRouteCircuitAuthorizationInner] identifier[beginCreateOrUpdate] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[circuitName] , identifier[String] identifier[authorizationName] , identifier[ExpressRouteCircuitAuthorizationInner] identifi... |
public Page<T> page(String sql, PageRow pageRow) {
return this.page(sql, paramValues, pageRow);
} | class class_name[name] begin[{]
method[page, return_type[type[Page]], modifier[public], parameter[sql, pageRow]] begin[{]
return[THIS[call[None.page, parameter[member[.sql], member[.paramValues], member[.pageRow]]]]]
end[}]
END[}] | Keyword[public] identifier[Page] operator[<] identifier[T] operator[>] identifier[page] operator[SEP] identifier[String] identifier[sql] , identifier[PageRow] identifier[pageRow] operator[SEP] {
Keyword[return] Keyword[this] operator[SEP] identifier[page] operator[SEP] identifier[sql] , identifier[paramValues]... |
public com.google.appengine.v1.LoginRequirement getLogin() {
com.google.appengine.v1.LoginRequirement result = com.google.appengine.v1.LoginRequirement.valueOf(login_);
return result == null ? com.google.appengine.v1.LoginRequirement.UNRECOGNIZED : result;
} | class class_name[name] begin[{]
method[getLogin, return_type[type[com]], modifier[public], parameter[]] begin[{]
local_variable[type[com], result]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=result, postfix_operators=[], prefix_operators=[], qualifier=, se... | Keyword[public] identifier[com] operator[SEP] identifier[google] operator[SEP] identifier[appengine] operator[SEP] identifier[v1] operator[SEP] identifier[LoginRequirement] identifier[getLogin] operator[SEP] operator[SEP] {
identifier[com] operator[SEP] identifier[google] operator[SEP] identifier[appengine] oper... |
public static String asciiCharactersEncoding(String str) throws QSException {
if (QSStringUtil.isEmpty(str)) {
return "";
}
try {
String encoded = URLEncoder.encode(str, QSConstant.ENCODING_UTF8);
encoded = encoded.replace("%2F", "/");
encoded = en... | class class_name[name] begin[{]
method[asciiCharactersEncoding, return_type[type[String]], modifier[public static], parameter[str]] begin[{]
if[call[QSStringUtil.isEmpty, parameter[member[.str]]]] begin[{]
return[literal[""]]
else begin[{]
None
end[}]
TryStat... | Keyword[public] Keyword[static] identifier[String] identifier[asciiCharactersEncoding] operator[SEP] identifier[String] identifier[str] operator[SEP] Keyword[throws] identifier[QSException] {
Keyword[if] operator[SEP] identifier[QSStringUtil] operator[SEP] identifier[isEmpty] operator[SEP] identifier[str] operat... |
@Override
public boolean moveToPosition(int position) {
try {
// For SQLite forward only, best we can do is assume the result set
// is at the beginning
for (int i = 0; i < position; i++) {
if (!resultSet.next()) {
return false;
}
}
} catch (SQLException e) {
throw new GeoPackageExcepti... | class class_name[name] begin[{]
method[moveToPosition, return_type[type[boolean]], modifier[public], parameter[position]] begin[{]
TryStatement(block=[ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[], member=next, postfix_operators=[], prefix_... | annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[moveToPosition] operator[SEP] Keyword[int] identifier[position] operator[SEP] {
Keyword[try] {
Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] identifier[po... |
public static int nthOccurrenceOf(final String s, final char needle, int n) {
checkNotNull(s);
checkArgument(n > 0);
for (int i = 0; i < s.length(); ++i) {
if (needle == s.charAt(i)) {
--n;
if (n == 0) {
return i;
}
}
}
return -1;
} | class class_name[name] begin[{]
method[nthOccurrenceOf, return_type[type[int]], modifier[public static], parameter[s, needle, n]] begin[{]
call[.checkNotNull, parameter[member[.s]]]
call[.checkArgument, parameter[binary_operation[member[.n], >, literal[0]]]]
ForStatement... | Keyword[public] Keyword[static] Keyword[int] identifier[nthOccurrenceOf] operator[SEP] Keyword[final] identifier[String] identifier[s] , Keyword[final] Keyword[char] identifier[needle] , Keyword[int] identifier[n] operator[SEP] {
identifier[checkNotNull] operator[SEP] identifier[s] operator[SEP] operator[SEP] ... |
static boolean isLatin(String s) {
int len = s.length();
for (int index = 0; index < len; index++) {
char c = s.charAt(index);
if (c > LARGEST_BASIC_LATIN) {
return false;
}
}
return true;
} | class class_name[name] begin[{]
method[isLatin, return_type[type[boolean]], modifier[static], parameter[s]] begin[{]
local_variable[type[int], len]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], in... | Keyword[static] Keyword[boolean] identifier[isLatin] operator[SEP] identifier[String] identifier[s] operator[SEP] {
Keyword[int] identifier[len] operator[=] identifier[s] operator[SEP] identifier[length] operator[SEP] operator[SEP] operator[SEP] Keyword[for] operator[SEP] Keyword[int] identifier[index] operator[... |
@Override
public String post_text(String path, String textData, boolean crumbFlag) throws IOException {
return post_text(path, textData, ContentType.DEFAULT_TEXT, crumbFlag);
} | class class_name[name] begin[{]
method[post_text, return_type[type[String]], modifier[public], parameter[path, textData, crumbFlag]] begin[{]
return[call[.post_text, parameter[member[.path], member[.textData], member[ContentType.DEFAULT_TEXT], member[.crumbFlag]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] identifier[String] identifier[post_text] operator[SEP] identifier[String] identifier[path] , identifier[String] identifier[textData] , Keyword[boolean] identifier[crumbFlag] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] identifier[pos... |
public static <T extends Descriptor> DescriptorImporter<T> importAs(final Class<T> type)
throws IllegalArgumentException {
return importAs(type, null);
} | class class_name[name] begin[{]
method[importAs, return_type[type[DescriptorImporter]], modifier[public static], parameter[type]] begin[{]
return[call[.importAs, parameter[member[.type], literal[null]]]]
end[}]
END[}] | Keyword[public] Keyword[static] operator[<] identifier[T] Keyword[extends] identifier[Descriptor] operator[>] identifier[DescriptorImporter] operator[<] identifier[T] operator[>] identifier[importAs] operator[SEP] Keyword[final] identifier[Class] operator[<] identifier[T] operator[>] identifier[type] operator[SEP] Keyw... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.