code stringlengths 130 281k | code_dependency stringlengths 182 306k |
|---|---|
public class class_name {
@Override
public EClass getIfcSensor() {
if (ifcSensorEClass == null) {
ifcSensorEClass = (EClass) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI).getEClassifiers()
.get(591);
}
return ifcSensorEClass;
} } | public class class_name {
@Override
public EClass getIfcSensor() {
if (ifcSensorEClass == null) {
ifcSensorEClass = (EClass) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI).getEClassifiers()
.get(591);
// depends on control dependency: [if], data = [none]
}
return ifcSensorEClass;
} ... |
public class class_name {
public synchronized boolean put(byte value) {
if (available == capacity) {
return false;
}
buffer[idxPut] = value;
idxPut = (idxPut + 1) % capacity;
available++;
return true;
} } | public class class_name {
public synchronized boolean put(byte value) {
if (available == capacity) {
return false; // depends on control dependency: [if], data = [none]
}
buffer[idxPut] = value;
idxPut = (idxPut + 1) % capacity;
available++;
return true;
... |
public class class_name {
public <T> SearchResult<T> querySearchResult(String query, Class<T> classOfT) {
InputStream instream = null;
try {
Reader reader = new InputStreamReader(instream = queryForStream(query), "UTF-8");
JsonObject json = new JsonParser().parse(reader).get... | public class class_name {
public <T> SearchResult<T> querySearchResult(String query, Class<T> classOfT) {
InputStream instream = null;
try {
Reader reader = new InputStreamReader(instream = queryForStream(query), "UTF-8");
JsonObject json = new JsonParser().parse(reader).get... |
public class class_name {
public String getText(Chronology chrono, TemporalField field, long value,
TextStyle style, Locale locale) {
if (chrono == IsoChronology.INSTANCE
|| !(field instanceof ChronoField)) {
return getText(field, value, style, lo... | public class class_name {
public String getText(Chronology chrono, TemporalField field, long value,
TextStyle style, Locale locale) {
if (chrono == IsoChronology.INSTANCE
|| !(field instanceof ChronoField)) {
return getText(field, value, style, lo... |
public class class_name {
@Override
public int doEndTag() throws JspException {
try {
String imgSrc = getImgSrcToRender();
if (null == var) {
try {
pageContext.getOut().print(imgSrc);
} catch (IOException e) {
throw new JspException(e);
}
} else {
pageContext.setAttribute(var, i... | public class class_name {
@Override
public int doEndTag() throws JspException {
try {
String imgSrc = getImgSrcToRender();
if (null == var) {
try {
pageContext.getOut().print(imgSrc); // depends on control dependency: [try], data = [none]
} catch (IOException e) {
throw new JspException(e)... |
public class class_name {
private static String getFileExtension(String path) {
int index = path.lastIndexOf('.');
if (index == -1) {
return null;
}
return path.substring(index + 1).toLowerCase(Locale.ENGLISH);
} } | public class class_name {
private static String getFileExtension(String path) {
int index = path.lastIndexOf('.');
if (index == -1) {
return null; // depends on control dependency: [if], data = [none]
}
return path.substring(index + 1).toLowerCase(Locale.ENGLISH);
} } |
public class class_name {
protected static void registerForPushNotification(Context context) {
if (checkPlayService(context)) {
WonderPushFirebaseMessagingService.fetchInstanceId();
} else {
Log.w(TAG, "Google Play Services not present. Check your setup. If on an emulator, use a... | public class class_name {
protected static void registerForPushNotification(Context context) {
if (checkPlayService(context)) {
WonderPushFirebaseMessagingService.fetchInstanceId(); // depends on control dependency: [if], data = [none]
} else {
Log.w(TAG, "Google Play Services n... |
public class class_name {
@Override
public Result<MZXMLIndexElement> buildIndex(final IndexBuilder.Info info) throws Exception {
Result<MZXMLIndexElement> result = new IndexBuilder.Result<>(info);
int numOpeningScanTagsFound = 0;
vars.reset();
XMLStreamReaderImpl reader = (pool == null) ? ne... | public class class_name {
@Override
public Result<MZXMLIndexElement> buildIndex(final IndexBuilder.Info info) throws Exception {
Result<MZXMLIndexElement> result = new IndexBuilder.Result<>(info);
int numOpeningScanTagsFound = 0;
vars.reset();
XMLStreamReaderImpl reader = (pool == null) ? ne... |
public class class_name {
@Override
public void visitEnd() {
if (name == null || name.length() == 0) {
reporter.error("The 'name' attribute of @Model from " + workbench.getType().getClassName() + " must be " +
"set");
return;
}
// Check the type... | public class class_name {
@Override
public void visitEnd() {
if (name == null || name.length() == 0) {
reporter.error("The 'name' attribute of @Model from " + workbench.getType().getClassName() + " must be " +
"set"); // depends on control dependency: [if], data = [none]
... |
public class class_name {
protected Box createTfra(StreamingTrack track) {
TrackFragmentRandomAccessBox tfra = new TrackFragmentRandomAccessBox();
tfra.setVersion(1); // use long offsets and times
long[] offsets = tfraOffsets.get(track);
long[] times = tfraTimes.get(track);
List... | public class class_name {
protected Box createTfra(StreamingTrack track) {
TrackFragmentRandomAccessBox tfra = new TrackFragmentRandomAccessBox();
tfra.setVersion(1); // use long offsets and times
long[] offsets = tfraOffsets.get(track);
long[] times = tfraTimes.get(track);
List... |
public class class_name {
public boolean containsValue(final int value)
{
boolean found = false;
if (value != missingValue)
{
final int[] entries = this.entries;
@DoNotSub final int length = entries.length;
for (@DoNotSub int valueIndex = 1; valueIndex <... | public class class_name {
public boolean containsValue(final int value)
{
boolean found = false;
if (value != missingValue)
{
final int[] entries = this.entries;
@DoNotSub final int length = entries.length;
for (@DoNotSub int valueIndex = 1; valueIndex <... |
public class class_name {
static boolean loadDat(String path)
{
try
{
ByteArray byteArray = ByteArray.createByteArray(path + Predefine.BIN_EXT);
if (byteArray == null) return false;
int size = byteArray.nextInt();
CoreDictionary.Attribute[] attributes... | public class class_name {
static boolean loadDat(String path)
{
try
{
ByteArray byteArray = ByteArray.createByteArray(path + Predefine.BIN_EXT);
if (byteArray == null) return false;
int size = byteArray.nextInt();
CoreDictionary.Attribute[] attributes... |
public class class_name {
private <I extends Message, O extends Message> ListenableFuture<JsonRpcResponse> invoke(
ServerMethod<I, O> method, JsonObject parameter, JsonElement id) {
I request;
try {
request = (I) Messages.fromJson(method.inputBuilder(), parameter);
} catch (Exception e) {
... | public class class_name {
private <I extends Message, O extends Message> ListenableFuture<JsonRpcResponse> invoke(
ServerMethod<I, O> method, JsonObject parameter, JsonElement id) {
I request;
try {
request = (I) Messages.fromJson(method.inputBuilder(), parameter); // depends on control dependency:... |
public class class_name {
public AioSession read(CompletionHandler<Integer, AioSession> handler) {
if (isOpen()) {
this.readBuffer.clear();
this.channel.read(this.readBuffer, Math.max(this.readTimeout, 0L), TimeUnit.MILLISECONDS, this, handler);
}
return this;
} } | public class class_name {
public AioSession read(CompletionHandler<Integer, AioSession> handler) {
if (isOpen()) {
this.readBuffer.clear();
// depends on control dependency: [if], data = [none]
this.channel.read(this.readBuffer, Math.max(this.readTimeout, 0L), TimeUnit.MILLISECONDS, this, handler);
// depe... |
public class class_name {
private void printDocument(Node node, Hashtable properties) {
// if node is empty do nothing... (Recursion)
if (node == null) {
return;
}
// initialise local variables
int type = node.getNodeType();
String name = node.getNodeName();... | public class class_name {
private void printDocument(Node node, Hashtable properties) {
// if node is empty do nothing... (Recursion)
if (node == null) {
return; // depends on control dependency: [if], data = [none]
}
// initialise local variables
int type = node.ge... |
public class class_name {
protected void setUser(String user) {
for (INodeHardLinkFile linkedFile : linkedFiles) {
linkedFile.setUser(user, false);
}
} } | public class class_name {
protected void setUser(String user) {
for (INodeHardLinkFile linkedFile : linkedFiles) {
linkedFile.setUser(user, false); // depends on control dependency: [for], data = [linkedFile]
}
} } |
public class class_name {
@Override
public <E> List<E> findAll(Class<E> entityClass, String[] columnsToSelect, Object... keys)
{
List<E> results = new ArrayList<E>();
if (columnsToSelect == null)
{
columnsToSelect = new String[0];
}
if (keys == null)
... | public class class_name {
@Override
public <E> List<E> findAll(Class<E> entityClass, String[] columnsToSelect, Object... keys)
{
List<E> results = new ArrayList<E>();
if (columnsToSelect == null)
{
columnsToSelect = new String[0]; // depends on control dependency: [if], dat... |
public class class_name {
public SimpleExpression<byte[]> asBinary() {
if (binary == null) {
binary = Expressions.operation(byte[].class, SpatialOps.AS_BINARY, mixin);
}
return binary;
} } | public class class_name {
public SimpleExpression<byte[]> asBinary() {
if (binary == null) {
binary = Expressions.operation(byte[].class, SpatialOps.AS_BINARY, mixin); // depends on control dependency: [if], data = [none]
}
return binary;
} } |
public class class_name {
public void addConverterFactory(final IStringConverterFactory converterFactory) {
addConverterInstanceFactory(new IStringConverterInstanceFactory() {
@SuppressWarnings("unchecked")
@Override
public IStringConverter<?> getConverterInstance(Parameter ... | public class class_name {
public void addConverterFactory(final IStringConverterFactory converterFactory) {
addConverterInstanceFactory(new IStringConverterInstanceFactory() {
@SuppressWarnings("unchecked")
@Override
public IStringConverter<?> getConverterInstance(Parameter ... |
public class class_name {
public int getNextPageWithoutDeletingIt(int prevPage) {
reportFreePage(prevPage);
if (iter.hasNextULL()) {
LongLongIndex.LLEntry e = iter.nextULL();
long pageId = e.getKey();
long value = e.getValue();
// do not return pages that are PID_DO_NOT_USE (i.e. negative value).
... | public class class_name {
public int getNextPageWithoutDeletingIt(int prevPage) {
reportFreePage(prevPage);
if (iter.hasNextULL()) {
LongLongIndex.LLEntry e = iter.nextULL();
long pageId = e.getKey();
long value = e.getValue();
// do not return pages that are PID_DO_NOT_USE (i.e. negative value).
... |
public class class_name {
public static Method getMethod(Class<?> clazz, boolean ignoreCase, String methodName, Class<?>... paramTypes) throws SecurityException {
if (null == clazz || StrUtil.isBlank(methodName)) {
return null;
}
final Method[] methods = getMethods(clazz);
if (ArrayUtil.isNotEmpty(me... | public class class_name {
public static Method getMethod(Class<?> clazz, boolean ignoreCase, String methodName, Class<?>... paramTypes) throws SecurityException {
if (null == clazz || StrUtil.isBlank(methodName)) {
return null;
// depends on control dependency: [if], data = [none]
}
final Method[] metho... |
public class class_name {
public static double calculateSlope( GridNode node, double flowValue ) {
double value = doubleNovalue;
if (!isNovalue(flowValue)) {
int flowDir = (int) flowValue;
if (flowDir != 10) {
Direction direction = Direction.forFlow(flowDir);
... | public class class_name {
public static double calculateSlope( GridNode node, double flowValue ) {
double value = doubleNovalue;
if (!isNovalue(flowValue)) {
int flowDir = (int) flowValue;
if (flowDir != 10) {
Direction direction = Direction.forFlow(flowDir);
... |
public class class_name {
public static OrderBook adaptOrderBook(
final RippleOrderBook rippleOrderBook,
final RippleMarketDataParams params,
final CurrencyPair currencyPair) {
final String orderBook =
rippleOrderBook.getOrderBook(); // e.g. XRP/BTC+rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B
f... | public class class_name {
public static OrderBook adaptOrderBook(
final RippleOrderBook rippleOrderBook,
final RippleMarketDataParams params,
final CurrencyPair currencyPair) {
final String orderBook =
rippleOrderBook.getOrderBook(); // e.g. XRP/BTC+rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B
f... |
public class class_name {
public PatternElementMatch getFirstLabeledMatch(String label) {
PatternElementMatch cur = this, result = null;
while (cur != null) {
String elementLabel = cur.patternElement.getLabel();
if (elementLabel != null && elementLabel.equals(label)) {
... | public class class_name {
public PatternElementMatch getFirstLabeledMatch(String label) {
PatternElementMatch cur = this, result = null;
while (cur != null) {
String elementLabel = cur.patternElement.getLabel();
if (elementLabel != null && elementLabel.equals(label)) {
... |
public class class_name {
@SuppressWarnings("unchecked")
@Override
public ChronoFormatter<T> with(Locale locale) {
if (locale.equals(this.globalAttributes.getLocale())) {
return this;
} else if (this.chronology.getChronoType() == CalendarDate.class) {
String pattern = t... | public class class_name {
@SuppressWarnings("unchecked")
@Override
public ChronoFormatter<T> with(Locale locale) {
if (locale.equals(this.globalAttributes.getLocale())) {
return this; // depends on control dependency: [if], data = [none]
} else if (this.chronology.getChronoType() =... |
public class class_name {
public void checkParameterizables() {
LoggingConfiguration.setVerbose(Level.VERBOSE);
knownParameterizables = new ArrayList<>();
try {
Enumeration<URL> us = getClass().getClassLoader().getResources(ELKIServiceLoader.RESOURCE_PREFIX);
while(us.hasMoreElements()) {
... | public class class_name {
public void checkParameterizables() {
LoggingConfiguration.setVerbose(Level.VERBOSE);
knownParameterizables = new ArrayList<>();
try {
Enumeration<URL> us = getClass().getClassLoader().getResources(ELKIServiceLoader.RESOURCE_PREFIX);
while(us.hasMoreElements()) {
... |
public class class_name {
public String getEasterSunday(int year, int days) {
int K = year / 100;
int M = 15 + ( ( 3 * K + 3 ) / 4 ) - ( ( 8 * K + 13 ) / 25 );
int S = 2 - ( (3 * K + 3) / 4 );
int A = year % 19;
int D = ( 19 * A + M ) % 30;
int R = ( D / 29) + ( ( D / 28 ) - ( D / 29 ) * ( A / 11 ) );
in... | public class class_name {
public String getEasterSunday(int year, int days) {
int K = year / 100;
int M = 15 + ( ( 3 * K + 3 ) / 4 ) - ( ( 8 * K + 13 ) / 25 );
int S = 2 - ( (3 * K + 3) / 4 );
int A = year % 19;
int D = ( 19 * A + M ) % 30;
int R = ( D / 29) + ( ( D / 28 ) - ( D / 29 ) * ( A / 11 ) );
in... |
public class class_name {
public DelegationSet withNameServers(String... nameServers) {
if (this.nameServers == null) {
setNameServers(new com.amazonaws.internal.SdkInternalList<String>(nameServers.length));
}
for (String ele : nameServers) {
this.nameServers.add(ele);
... | public class class_name {
public DelegationSet withNameServers(String... nameServers) {
if (this.nameServers == null) {
setNameServers(new com.amazonaws.internal.SdkInternalList<String>(nameServers.length)); // depends on control dependency: [if], data = [none]
}
for (String ele : n... |
public class class_name {
public void marshall(GetBotVersionsRequest getBotVersionsRequest, ProtocolMarshaller protocolMarshaller) {
if (getBotVersionsRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshalle... | public class class_name {
public void marshall(GetBotVersionsRequest getBotVersionsRequest, ProtocolMarshaller protocolMarshaller) {
if (getBotVersionsRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshalle... |
public class class_name {
public <T> File writeLines(Collection<T> list, LineSeparator lineSeparator, boolean isAppend) throws IORuntimeException {
try (PrintWriter writer = getPrintWriter(isAppend)){
for (T t : list) {
if (null != t) {
writer.print(t.toString());
printNewLine(writer, lineSepar... | public class class_name {
public <T> File writeLines(Collection<T> list, LineSeparator lineSeparator, boolean isAppend) throws IORuntimeException {
try (PrintWriter writer = getPrintWriter(isAppend)){
for (T t : list) {
if (null != t) {
writer.print(t.toString());
// depends on control dependency: [... |
public class class_name {
@SuppressWarnings("ProhibitedExceptionDeclared")
@PostConstruct
public void init() throws Exception {
final String configFileLocation = getConfigFileLocation();
T fileConfig = getEmptyConfig();
boolean fileExists = false;
log.info("Using {} as config ... | public class class_name {
@SuppressWarnings("ProhibitedExceptionDeclared")
@PostConstruct
public void init() throws Exception {
final String configFileLocation = getConfigFileLocation();
T fileConfig = getEmptyConfig();
boolean fileExists = false;
log.info("Using {} as config ... |
public class class_name {
public <P extends ParaObject> P read(String id) {
if (StringUtils.isBlank(id)) {
return null;
}
Map<String, Object> data = getEntity(invokeGet("_id/".concat(id), null), Map.class);
return ParaObjectUtils.setAnnotatedFields(data);
} } | public class class_name {
public <P extends ParaObject> P read(String id) {
if (StringUtils.isBlank(id)) {
return null; // depends on control dependency: [if], data = [none]
}
Map<String, Object> data = getEntity(invokeGet("_id/".concat(id), null), Map.class);
return ParaObjectUtils.setAnnotatedFields(data)... |
public class class_name {
@Deprecated
BasicUser getCurrentUserBasic(AccessToken accessToken) {
checkAccessTokenIsNotNull(accessToken);
StatusType status;
String content;
try {
Response response = targetEndpoint.path("me").request(MediaType.APPLICATION_JSON)
... | public class class_name {
@Deprecated
BasicUser getCurrentUserBasic(AccessToken accessToken) {
checkAccessTokenIsNotNull(accessToken);
StatusType status;
String content;
try {
Response response = targetEndpoint.path("me").request(MediaType.APPLICATION_JSON)
... |
public class class_name {
public GridCell<P> removeCellAt(int row, int column) {
final GridCell<P> cell = this.cells[row][column];
if (cell != null) {
this.cells[row][column] = null;
--this.cellCount;
for (final P element : cell) {
removeElement(element);
}
}
return cell;
} } | public class class_name {
public GridCell<P> removeCellAt(int row, int column) {
final GridCell<P> cell = this.cells[row][column];
if (cell != null) {
this.cells[row][column] = null; // depends on control dependency: [if], data = [none]
--this.cellCount; // depends on control dependency: [if], data = [none]
... |
public class class_name {
public Page transform(Factory factory, ConfigImpl config, PageSource ps, TagLib[] tlibs, FunctionLib[] flibs, boolean returnValue, boolean ignoreScopes)
throws TemplateException, IOException {
Page p;
SourceCode sc;
boolean writeLog = config.getExecutionLogEnabled();
Charset charse... | public class class_name {
public Page transform(Factory factory, ConfigImpl config, PageSource ps, TagLib[] tlibs, FunctionLib[] flibs, boolean returnValue, boolean ignoreScopes)
throws TemplateException, IOException {
Page p;
SourceCode sc;
boolean writeLog = config.getExecutionLogEnabled();
Charset charse... |
public class class_name {
public static boolean stopProcess(final AbstractProcessorThread proc) {
proc.info("************************************************************");
proc.info(" * Stopping " + proc.getName());
proc.info("************************************************************");
proc.setRu... | public class class_name {
public static boolean stopProcess(final AbstractProcessorThread proc) {
proc.info("************************************************************");
proc.info(" * Stopping " + proc.getName());
proc.info("************************************************************");
proc.setRu... |
public class class_name {
private static String getBundle(String friendlyName, String className, int truncate)
{
try {
cl.loadClass(className);
int start = className.length();
for (int i = 0; i < truncate; ++i)
start = className.lastIndexOf('.', start - 1);
final String bundle = className.sub... | public class class_name {
private static String getBundle(String friendlyName, String className, int truncate)
{
try {
cl.loadClass(className);
// depends on control dependency: [try], data = [none]
int start = className.length();
for (int i = 0; i < truncate; ++i)
start = className.lastIndexOf('... |
public class class_name {
public static Point3D_F64 closestPoint(LineSegment3D_F64 line, Point3D_F64 pt, Point3D_F64 ret) {
if( ret == null ) {
ret = new Point3D_F64();
}
double dx = pt.x - line.a.x;
double dy = pt.y - line.a.y;
double dz = pt.z - line.a.z;
double slope_x = line.b.x - line.a.x;
doub... | public class class_name {
public static Point3D_F64 closestPoint(LineSegment3D_F64 line, Point3D_F64 pt, Point3D_F64 ret) {
if( ret == null ) {
ret = new Point3D_F64(); // depends on control dependency: [if], data = [none]
}
double dx = pt.x - line.a.x;
double dy = pt.y - line.a.y;
double dz = pt.z - lin... |
public class class_name {
private ClientImpl createClientAndConnect() throws UnknownHostException, IOException
{
// Make client connections.
ClientImpl clientTmp = (ClientImpl) ClientFactory.createClient(this.config);
// ENG-6231: Only fail if we can't connect to any of the provided servers... | public class class_name {
private ClientImpl createClientAndConnect() throws UnknownHostException, IOException
{
// Make client connections.
ClientImpl clientTmp = (ClientImpl) ClientFactory.createClient(this.config);
// ENG-6231: Only fail if we can't connect to any of the provided servers... |
public class class_name {
public void setFilter(UnicodeFilter filter) {
if (filter == null) {
this.filter = null;
} else {
try {
// fast high-runner case
this.filter = new UnicodeSet((UnicodeSet)filter).freeze();
} catch (Exception e) ... | public class class_name {
public void setFilter(UnicodeFilter filter) {
if (filter == null) {
this.filter = null; // depends on control dependency: [if], data = [none]
} else {
try {
// fast high-runner case
this.filter = new UnicodeSet((UnicodeSe... |
public class class_name {
@Override
public final String getFor(final Class<?> pClass, final String pThingName) {
if ("list".equals(pThingName)) {
if (pClass == PaymentFrom.class || pClass == PaymentTo.class
|| pClass == PrepaymentFrom.class || pClass == PrepaymentTo.class
|| pClass == Sub... | public class class_name {
@Override
public final String getFor(final Class<?> pClass, final String pThingName) {
if ("list".equals(pThingName)) {
if (pClass == PaymentFrom.class || pClass == PaymentTo.class
|| pClass == PrepaymentFrom.class || pClass == PrepaymentTo.class
|| pClass == Sub... |
public class class_name {
public static @Nullable Dimension getDimension(@NotNull Rendition rendition,
boolean suppressLogWarningNoRenditionsMetadata) {
String fileExtension = FilenameUtils.getExtension(getFilename(rendition));
if (!FileExtension.isImage(fileExtension)) {
// this is not a supporte... | public class class_name {
public static @Nullable Dimension getDimension(@NotNull Rendition rendition,
boolean suppressLogWarningNoRenditionsMetadata) {
String fileExtension = FilenameUtils.getExtension(getFilename(rendition));
if (!FileExtension.isImage(fileExtension)) {
// this is not a supporte... |
public class class_name {
private boolean getThenPerformAdj(int operation, int position, boolean value) {
checkMutable();
final int i = position >> ADDRESS_BITS;
final long m = 1L << (position & ADDRESS_MASK);
final long v = bits[i] & m;
switch(operation) {
case SET :
if (value) {
bits[i] |= m;
... | public class class_name {
private boolean getThenPerformAdj(int operation, int position, boolean value) {
checkMutable();
final int i = position >> ADDRESS_BITS;
final long m = 1L << (position & ADDRESS_MASK);
final long v = bits[i] & m;
switch(operation) {
case SET :
if (value) {
bits[i] |= m; // ... |
public class class_name {
public static <T> T fromXml(File xmlPath, Class<T> type) {
BufferedReader reader = null;
StringBuilder sb = null;
try {
reader = new BufferedReader(new InputStreamReader(new FileInputStream(xmlPath), ENCODING));
String line = null;
s... | public class class_name {
public static <T> T fromXml(File xmlPath, Class<T> type) {
BufferedReader reader = null;
StringBuilder sb = null;
try {
reader = new BufferedReader(new InputStreamReader(new FileInputStream(xmlPath), ENCODING)); // depends on control dependency: [try], data... |
public class class_name {
public final void release() {
synchronized (this.LOCK) {
if ((this.owner != null)
&& (this.owner.get() == Thread.currentThread())) {
this.acquire--;
if (this.acquire == 0) {
this.owner = null;
this.LOCK.notify();
}
return;
}
if ((this.owner != null... | public class class_name {
public final void release() {
synchronized (this.LOCK) {
if ((this.owner != null)
&& (this.owner.get() == Thread.currentThread())) {
this.acquire--; // depends on control dependency: [if], data = [none]
if (this.acquire == 0) {
this.owner = null; // depends on control ... |
public class class_name {
@Override
public void shutdown() {
log.info("Shutting down Ontology crawlers.");
this.executor.shutdown(); // Disable new tasks from being submitted
try {
// Wait a while for existing tasks to terminate
if (!this.executor.awaitTermination(5,... | public class class_name {
@Override
public void shutdown() {
log.info("Shutting down Ontology crawlers.");
this.executor.shutdown(); // Disable new tasks from being submitted
try {
// Wait a while for existing tasks to terminate
if (!this.executor.awaitTermination(5,... |
public class class_name {
protected void generateIScriptBuilder() {
final List<StringConcatenationClient> topElements = generateTopElements(true, false);
final TypeReference builder = getScriptBuilderInterface();
final StringConcatenationClient content = new StringConcatenationClient() {
@Override
protecte... | public class class_name {
protected void generateIScriptBuilder() {
final List<StringConcatenationClient> topElements = generateTopElements(true, false);
final TypeReference builder = getScriptBuilderInterface();
final StringConcatenationClient content = new StringConcatenationClient() {
@Override
protecte... |
public class class_name {
@Override
public void doRender(final WComponent component, final WebXmlRenderContext renderContext) {
WSelectToggle toggle = (WSelectToggle) component;
XmlStringBuilder xml = renderContext.getWriter();
xml.appendTagOpen("ui:selecttoggle");
xml.appendAttribute("id", component.getId()... | public class class_name {
@Override
public void doRender(final WComponent component, final WebXmlRenderContext renderContext) {
WSelectToggle toggle = (WSelectToggle) component;
XmlStringBuilder xml = renderContext.getWriter();
xml.appendTagOpen("ui:selecttoggle");
xml.appendAttribute("id", component.getId()... |
public class class_name {
public boolean removeHandler(PacketHandler handler) {
synchronized (this.handlers) {
boolean removed = this.handlers.remove(handler);
if (removed) {
this.count.decrementAndGet();
}
return removed;
}
} } | public class class_name {
public boolean removeHandler(PacketHandler handler) {
synchronized (this.handlers) {
boolean removed = this.handlers.remove(handler);
if (removed) {
this.count.decrementAndGet(); // depends on control dependency: [if], data = [none]
... |
public class class_name {
public java.util.List<UnsuccessfulItem> getUnsuccessful() {
if (unsuccessful == null) {
unsuccessful = new com.amazonaws.internal.SdkInternalList<UnsuccessfulItem>();
}
return unsuccessful;
} } | public class class_name {
public java.util.List<UnsuccessfulItem> getUnsuccessful() {
if (unsuccessful == null) {
unsuccessful = new com.amazonaws.internal.SdkInternalList<UnsuccessfulItem>(); // depends on control dependency: [if], data = [none]
}
return unsuccessful;
} } |
public class class_name {
void validate(KnowledgeSource knowledgeSource) throws
LinkValidationFailedException, KnowledgeSourceReadException {
List<String> invalidPropIds = new ArrayList<>();
List<PropositionDefinition> propDefs = knowledgeSource.readPropositionDefinitions(this.propIdsAsSet.... | public class class_name {
void validate(KnowledgeSource knowledgeSource) throws
LinkValidationFailedException, KnowledgeSourceReadException {
List<String> invalidPropIds = new ArrayList<>();
List<PropositionDefinition> propDefs = knowledgeSource.readPropositionDefinitions(this.propIdsAsSet.... |
public class class_name {
public static SettingsSchema get(Map<String, String[]> clArgs, SettingsCommand command)
{
String[] params = clArgs.remove("-schema");
if (params == null)
return new SettingsSchema(new Options(), command);
if (command instanceof SettingsCommandUser)
... | public class class_name {
public static SettingsSchema get(Map<String, String[]> clArgs, SettingsCommand command)
{
String[] params = clArgs.remove("-schema");
if (params == null)
return new SettingsSchema(new Options(), command);
if (command instanceof SettingsCommandUser)
... |
public class class_name {
public List<Instruction> reduceInstructions(final List<Instruction> instructions) {
lock.lock();
try {
this.instructions = instructions;
stackSizeSimulator.buildStackSizes(instructions);
return reduceInstructionsInternal(instructions);
... | public class class_name {
public List<Instruction> reduceInstructions(final List<Instruction> instructions) {
lock.lock();
try {
this.instructions = instructions; // depends on control dependency: [try], data = [none]
stackSizeSimulator.buildStackSizes(instructions); // depends ... |
public class class_name {
public void write(int b) throws IOException {
while (true) {
lockW.lock();
try {
// fail if closed
checkClosed();
if (length - availableCount.get() > 0) {
bytes[writeCursor] = (byte) b;
incWriteCursor(1);
available... | public class class_name {
public void write(int b) throws IOException {
while (true) {
lockW.lock();
try {
// fail if closed
checkClosed(); // depends on control dependency: [try], data = [none]
if (length - availableCount.get() > 0) {
bytes[writeCursor] = (by... |
public class class_name {
public PrivateKey getPrivateKey(String alias, String password) {
Key key = getKey(alias, password);
if (key instanceof PrivateKey) {
return (PrivateKey) key;
} else {
throw new IllegalStateException(format("Key with alias '%s' was not a private ... | public class class_name {
public PrivateKey getPrivateKey(String alias, String password) {
Key key = getKey(alias, password);
if (key instanceof PrivateKey) {
return (PrivateKey) key; // depends on control dependency: [if], data = [none]
} else {
throw new IllegalStateEx... |
public class class_name {
public static SerializationFormat getOutputFormat(String name) {
for (SerializationFormat ft : Instance.serializationFormats) {
if (ft.isAcceptedAsOutput(name)) {
return ft;
}
}
return null;
} } | public class class_name {
public static SerializationFormat getOutputFormat(String name) {
for (SerializationFormat ft : Instance.serializationFormats) {
if (ft.isAcceptedAsOutput(name)) {
return ft; // depends on control dependency: [if], data = [none]
}
}
... |
public class class_name {
private void populateAnnotations(Collection<Annotation> annotations) {
for (Annotation each : annotations) {
this.annotations.put(each.annotationType(), each);
}
} } | public class class_name {
private void populateAnnotations(Collection<Annotation> annotations) {
for (Annotation each : annotations) {
this.annotations.put(each.annotationType(), each); // depends on control dependency: [for], data = [each]
}
} } |
public class class_name {
public static void printStoreMap(Reflections reflections) {
LOGGER.info("Now we will print store map......");
Store store = reflections.getStore();
Map<String/* indexName */, Multimap<String, String>> storeMap = store.getStoreMap();
for (String indexName : st... | public class class_name {
public static void printStoreMap(Reflections reflections) {
LOGGER.info("Now we will print store map......");
Store store = reflections.getStore();
Map<String/* indexName */, Multimap<String, String>> storeMap = store.getStoreMap();
for (String indexName : st... |
public class class_name {
Optional<String> writeMeter(Meter meter) {
Iterable<Measurement> measurements = meter.measure();
List<String> names = new ArrayList<>();
// Snapshot values should be used throughout this method as there are chances for values to be changed in-between.
List<Doub... | public class class_name {
Optional<String> writeMeter(Meter meter) {
Iterable<Measurement> measurements = meter.measure();
List<String> names = new ArrayList<>();
// Snapshot values should be used throughout this method as there are chances for values to be changed in-between.
List<Doub... |
public class class_name {
private void generateEntity(M2MEntity entity) {
entity.propertyPrimaryKey = TypeName.LONG;
entity.propertyKey1 = findPrimaryKeyFieldType(entity.entity1Name.toString());
entity.propertyKey2 = findPrimaryKeyFieldType(entity.entity2Name.toString());
if (!entity.needToCreate) {
return;... | public class class_name {
private void generateEntity(M2MEntity entity) {
entity.propertyPrimaryKey = TypeName.LONG;
entity.propertyKey1 = findPrimaryKeyFieldType(entity.entity1Name.toString());
entity.propertyKey2 = findPrimaryKeyFieldType(entity.entity2Name.toString());
if (!entity.needToCreate) {
return;... |
public class class_name {
public void log(Logger logger, LogLevel priority) {
if (LoggerWrap.isEnabledFor(logger, priority)) {
String timerLabel;
if (threadId != 0) {
timerLabel = name + " (thread " + threadId + ")";
} else if (threadCount > 1) {
timerLabel = name + " (over " + threadCount + " threa... | public class class_name {
public void log(Logger logger, LogLevel priority) {
if (LoggerWrap.isEnabledFor(logger, priority)) {
String timerLabel;
if (threadId != 0) {
timerLabel = name + " (thread " + threadId + ")"; // depends on control dependency: [if], data = [none]
} else if (threadCount > 1) {
... |
public class class_name {
@Override
public EEnum getIfcWindowStyleConstructionEnum() {
if (ifcWindowStyleConstructionEnumEEnum == null) {
ifcWindowStyleConstructionEnumEEnum = (EEnum) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(1104);
}
return ifcWindowStyleC... | public class class_name {
@Override
public EEnum getIfcWindowStyleConstructionEnum() {
if (ifcWindowStyleConstructionEnumEEnum == null) {
ifcWindowStyleConstructionEnumEEnum = (EEnum) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(1104);
// depends on control depende... |
public class class_name {
private boolean unpackLibrary(String path) {
boolean retval = false;
try {
final Enumeration<URL> c = JNILibrary.class.getClassLoader()
.getResources(path);
while (c.hasMoreElements()) {
final URL url = c.nextElement();
log.trace("path: {}; url:... | public class class_name {
private boolean unpackLibrary(String path) {
boolean retval = false;
try {
final Enumeration<URL> c = JNILibrary.class.getClassLoader()
.getResources(path);
while (c.hasMoreElements()) {
final URL url = c.nextElement();
log.trace("path: {}; url:... |
public class class_name {
protected void removeNeighborFromRoutingTable(final TrustGraphNodeId neighbor) {
/* find the neighbor that the node being removed is mapped to
* ie the route neighbor -> mergeVal
*/
final TrustGraphNodeId mergeVal = routingTable.get(neighbor);
// if... | public class class_name {
protected void removeNeighborFromRoutingTable(final TrustGraphNodeId neighbor) {
/* find the neighbor that the node being removed is mapped to
* ie the route neighbor -> mergeVal
*/
final TrustGraphNodeId mergeVal = routingTable.get(neighbor);
// if... |
public class class_name {
@Override
public Position get(Position pos, List<Event<T>> list) {
EventBatch<T> b;
// Return null if the position is out of retention or in the indexed form.
if(pos.getOffset() < getOrigin() || pos.isIndexed()) {
return null;
}
... | public class class_name {
@Override
public Position get(Position pos, List<Event<T>> list) {
EventBatch<T> b;
// Return null if the position is out of retention or in the indexed form.
if(pos.getOffset() < getOrigin() || pos.isIndexed()) {
return null; // depends on con... |
public class class_name {
bbBlock truncate(Object caller, int version, int pos) {
assert mutation_in_progress(caller, version);
if (0 > pos || pos > this._buf_limit )
throw new IllegalArgumentException();
// clear out all the blocks in use from the last in use
// to the bloc... | public class class_name {
bbBlock truncate(Object caller, int version, int pos) {
assert mutation_in_progress(caller, version);
if (0 > pos || pos > this._buf_limit )
throw new IllegalArgumentException();
// clear out all the blocks in use from the last in use
// to the bloc... |
public class class_name {
public void setStyle(String style) {
if (CmsStringUtil.isNotEmptyOrWhitespaceOnly(m_style)) {
m_component.removeStyleName(m_style);
}
m_style = style;
if (CmsStringUtil.isNotEmptyOrWhitespaceOnly(m_style)) {
m_component.addStyleName(m_s... | public class class_name {
public void setStyle(String style) {
if (CmsStringUtil.isNotEmptyOrWhitespaceOnly(m_style)) {
m_component.removeStyleName(m_style); // depends on control dependency: [if], data = [none]
}
m_style = style;
if (CmsStringUtil.isNotEmptyOrWhitespaceOnl... |
public class class_name {
public List<Concept> getPathToRoot() {
LinkedList<Concept> path = new LinkedList<>();
Concept node = this;
while (node != null) {
path.add(node);
node = node.parent;
}
return path;
} } | public class class_name {
public List<Concept> getPathToRoot() {
LinkedList<Concept> path = new LinkedList<>();
Concept node = this;
while (node != null) {
path.add(node); // depends on control dependency: [while], data = [(node]
node = node.parent; // depends on contro... |
public class class_name {
public Map<K, List<Versioned<V>>> getAllWithCustomTimeout(CompositeVoldemortRequest<K, V> requestWrapper) {
validateTimeout(requestWrapper.getRoutingTimeoutInMs());
Map<K, List<Versioned<V>>> items = null;
for(int attempts = 0;; attempts++) {
if(attempts >=... | public class class_name {
public Map<K, List<Versioned<V>>> getAllWithCustomTimeout(CompositeVoldemortRequest<K, V> requestWrapper) {
validateTimeout(requestWrapper.getRoutingTimeoutInMs());
Map<K, List<Versioned<V>>> items = null;
for(int attempts = 0;; attempts++) {
if(attempts >=... |
public class class_name {
public static void write(
DataOutputStream out,
Map<String, String> importedAnnotations,
Map<String, Set<String>> packageAnnotations,
Map<String, Set<String>> typeAnnotations,
Map<String, MethodAnnotationsRecord> methodRecords)
throws IOException {
// F... | public class class_name {
public static void write(
DataOutputStream out,
Map<String, String> importedAnnotations,
Map<String, Set<String>> packageAnnotations,
Map<String, Set<String>> typeAnnotations,
Map<String, MethodAnnotationsRecord> methodRecords)
throws IOException {
// F... |
public class class_name {
private LazyFileBasedLongCollection getCollectionForKey(final K key) {
LazyFileBasedLongCollection collection = hashFiles.get(key);
if (collection == null) {
collection = new LazyFileBasedLongCollection(basePath + File.separator + key.hashCode() + ".lfc", clearOnOpen);
hashFiles.p... | public class class_name {
private LazyFileBasedLongCollection getCollectionForKey(final K key) {
LazyFileBasedLongCollection collection = hashFiles.get(key);
if (collection == null) {
collection = new LazyFileBasedLongCollection(basePath + File.separator + key.hashCode() + ".lfc", clearOnOpen); // depends on ... |
public class class_name {
private void setResourceIdOnFaceletsMode(FacesContext facesContext, UIComponent component,
Class<?> inspectedClass)
{
if (component.getId() == null)
{
FaceletCompositionContext mctx = FaceletCompositionContext.getCurrentInstance(facesContext);
... | public class class_name {
private void setResourceIdOnFaceletsMode(FacesContext facesContext, UIComponent component,
Class<?> inspectedClass)
{
if (component.getId() == null)
{
FaceletCompositionContext mctx = FaceletCompositionContext.getCurrentInstance(facesContext);
... |
public class class_name {
protected final void setModelResources(final URI... modelResources) {
if (modelResources == null) {
this.modelResources = null;
} else {
this.modelResources = new ArrayList<URI>();
this.modelResources.addAll(Arrays.asList(modelResources... | public class class_name {
protected final void setModelResources(final URI... modelResources) {
if (modelResources == null) {
this.modelResources = null;
// depends on control dependency: [if], data = [none]
} else {
this.modelResources = new ArrayList<URI>();
// depends on... |
public class class_name {
public boolean createEntity(Dao dao, Entity<?> en) {
StringBuilder sb = new StringBuilder("CREATE TABLE " + en.getTableName() + "(");
// 创建字段
for (MappingField mf : en.getMappingFields()) {
if (mf.isReadonly())
continue;
sb.appen... | public class class_name {
public boolean createEntity(Dao dao, Entity<?> en) {
StringBuilder sb = new StringBuilder("CREATE TABLE " + en.getTableName() + "(");
// 创建字段
for (MappingField mf : en.getMappingFields()) {
if (mf.isReadonly())
continue;
sb.appen... |
public class class_name {
public void setEndpoint(String endpoint) {
this.endpoint = endpoint;
if (bugsnag != null) {
bugsnag.setEndpoints(endpoint, null);
}
} } | public class class_name {
public void setEndpoint(String endpoint) {
this.endpoint = endpoint;
if (bugsnag != null) {
bugsnag.setEndpoints(endpoint, null); // depends on control dependency: [if], data = [null)]
}
} } |
public class class_name {
public static Iterator<Object> getValues(Object[] array)
{
if (array == null)
{
return null;
}
ArrayList<Object> valueList = new ArrayList<Object>();
int i = array.length - 1;
while (i >= 0)
{
valueList.add(ar... | public class class_name {
public static Iterator<Object> getValues(Object[] array)
{
if (array == null)
{
return null; // depends on control dependency: [if], data = [none]
}
ArrayList<Object> valueList = new ArrayList<Object>();
int i = array.length - 1;
... |
public class class_name {
public StrBuilder insert(final int index, final Object obj) {
if (obj == null) {
return insert(index, nullText);
}
return insert(index, obj.toString());
} } | public class class_name {
public StrBuilder insert(final int index, final Object obj) {
if (obj == null) {
return insert(index, nullText); // depends on control dependency: [if], data = [none]
}
return insert(index, obj.toString());
} } |
public class class_name {
void handleInitialRequest(HttpServerExchange initial, Http2Channel channel, byte[] data) {
//we have a request
Http2HeadersStreamSinkChannel sink = channel.createInitialUpgradeResponseStream();
final Http2ServerConnection connection = new Http2ServerConnection(channel... | public class class_name {
void handleInitialRequest(HttpServerExchange initial, Http2Channel channel, byte[] data) {
//we have a request
Http2HeadersStreamSinkChannel sink = channel.createInitialUpgradeResponseStream();
final Http2ServerConnection connection = new Http2ServerConnection(channel... |
public class class_name {
public QueryParameters get(int index) {
if (getCurrentResultSet() == null && index > 0 && valueCached(index) == false) {
// don't have anymore values in cache
return null;
}
QueryParameters params = null;
try {
if (valueCac... | public class class_name {
public QueryParameters get(int index) {
if (getCurrentResultSet() == null && index > 0 && valueCached(index) == false) {
// don't have anymore values in cache
return null; // depends on control dependency: [if], data = [none]
}
QueryParameters ... |
public class class_name {
@WebOperationMethod
public Map<String,Object> downloadAsFile(Map<String, Object> params, HttpServletRequest request, HttpServletResponse response) throws Exception {
String database = Objects.get(params, "database");
String collection = Objects.get(params, "collection", CO... | public class class_name {
@WebOperationMethod
public Map<String,Object> downloadAsFile(Map<String, Object> params, HttpServletRequest request, HttpServletResponse response) throws Exception {
String database = Objects.get(params, "database");
String collection = Objects.get(params, "collection", CO... |
public class class_name {
public void initialize(UimaContext aContext) throws ResourceInitializationException {
super.initialize(aContext);
// initialize annotator logger
this.logger = getContext().getLogger();
// default initialization for number format
this.floatNumberFormat = NumberFormat.getNumber... | public class class_name {
public void initialize(UimaContext aContext) throws ResourceInitializationException {
super.initialize(aContext);
// initialize annotator logger
this.logger = getContext().getLogger();
// default initialization for number format
this.floatNumberFormat = NumberFormat.getNumber... |
public class class_name {
@Override
public boolean isJobInstancePurgeable(long jobInstanceId) {
InstanceState instanceState = getJobInstance(jobInstanceId).getInstanceState();
if (instanceState.equals(InstanceState.SUBMITTED)
|| instanceState.equals(InstanceState.JMS_QUEUED)
... | public class class_name {
@Override
public boolean isJobInstancePurgeable(long jobInstanceId) {
InstanceState instanceState = getJobInstance(jobInstanceId).getInstanceState();
if (instanceState.equals(InstanceState.SUBMITTED)
|| instanceState.equals(InstanceState.JMS_QUEUED)
... |
public class class_name {
public static boolean validateClassLoadable(ClassNotFoundException cnfe, ClassLoader cl) {
try {
String className = cnfe.getMessage();
Class.forName(className, false, cl);
return true;
}
catch (ClassNotFoundException e) {
return false;
}
catch (Exception e) {
return f... | public class class_name {
public static boolean validateClassLoadable(ClassNotFoundException cnfe, ClassLoader cl) {
try {
String className = cnfe.getMessage();
Class.forName(className, false, cl);
return true; // depends on control dependency: [try], data = [none]
}
catch (ClassNotFoundException e) {
... |
public class class_name {
public List<CommonEvent> asCommonEvents(final JAXBContext ctx) {
final List<CommonEvent> list = new ArrayList<CommonEvent>();
for (final Event event : events) {
list.add(event.asCommonEvent(ctx));
}
return list;
} } | public class class_name {
public List<CommonEvent> asCommonEvents(final JAXBContext ctx) {
final List<CommonEvent> list = new ArrayList<CommonEvent>();
for (final Event event : events) {
list.add(event.asCommonEvent(ctx));
// depends on control dependency: [for], data = [event]
... |
public class class_name {
protected String getSoapAction() {
String soapAction = null;
try {
soapAction = getAttributeValueSmart(SOAP_ACTION);
}
catch (PropertyException ex) {
logger.severeException(ex.getMessage(), ex);
}
if (soapAction == null)... | public class class_name {
protected String getSoapAction() {
String soapAction = null;
try {
soapAction = getAttributeValueSmart(SOAP_ACTION); // depends on control dependency: [try], data = [none]
}
catch (PropertyException ex) {
logger.severeException(ex.getMes... |
public class class_name {
static PrefsTransform getUtilTransform(TypeName type) {
String typeName = type.toString();
// Integer.class.getCanonicalName().equals(typeName)
if (Date.class.getCanonicalName().equals(typeName)) {
return new DatePrefsTransform();
}
if (Locale.class.getCanonicalName().equals(typ... | public class class_name {
static PrefsTransform getUtilTransform(TypeName type) {
String typeName = type.toString();
// Integer.class.getCanonicalName().equals(typeName)
if (Date.class.getCanonicalName().equals(typeName)) {
return new DatePrefsTransform(); // depends on control dependency: [if], data = [none... |
public class class_name {
public static void addOrSetAttribute(final AttributesImpl atts, final Node att) {
if (att.getNodeType() != Node.ATTRIBUTE_NODE) {
throw new IllegalArgumentException();
}
final Attr a = (Attr) att;
String localName = a.getLocalName();
if (loc... | public class class_name {
public static void addOrSetAttribute(final AttributesImpl atts, final Node att) {
if (att.getNodeType() != Node.ATTRIBUTE_NODE) {
throw new IllegalArgumentException();
}
final Attr a = (Attr) att;
String localName = a.getLocalName();
if (loc... |
public class class_name {
@Nullable
public String getState() {
lifecycleLock.readLock().lock();
try {
return state == null ? null : state.toString();
} finally {
lifecycleLock.readLock().unlock();
}
} } | public class class_name {
@Nullable
public String getState() {
lifecycleLock.readLock().lock();
try {
return state == null ? null : state.toString(); // depends on control dependency: [try], data = [none]
} finally {
lifecycleLock.readLock().unlock();
}
}... |
public class class_name {
public void setPredecessorRuns(java.util.Collection<Predecessor> predecessorRuns) {
if (predecessorRuns == null) {
this.predecessorRuns = null;
return;
}
this.predecessorRuns = new java.util.ArrayList<Predecessor>(predecessorRuns);
} } | public class class_name {
public void setPredecessorRuns(java.util.Collection<Predecessor> predecessorRuns) {
if (predecessorRuns == null) {
this.predecessorRuns = null; // depends on control dependency: [if], data = [none]
return; // depends on control dependency: [if], data = [none]
... |
public class class_name {
public List<Sid> getSids(Authentication authentication) {
Collection<? extends GrantedAuthority> authorities = roleHierarchy
.getReachableGrantedAuthorities(authentication.getAuthorities());
List<Sid> sids = new ArrayList<>(authorities.size() + 1);
sids.add(new PrincipalSid(authent... | public class class_name {
public List<Sid> getSids(Authentication authentication) {
Collection<? extends GrantedAuthority> authorities = roleHierarchy
.getReachableGrantedAuthorities(authentication.getAuthorities());
List<Sid> sids = new ArrayList<>(authorities.size() + 1);
sids.add(new PrincipalSid(authent... |
public class class_name {
public void start() {
int errors = 0;
// Use getFile() instead of direct access to fileName because
// the function is overridden in RollingFileAppender, which
// returns a value that doesn't necessarily match fileName.
String file = getFile();
if (file != null) {
... | public class class_name {
public void start() {
int errors = 0;
// Use getFile() instead of direct access to fileName because
// the function is overridden in RollingFileAppender, which
// returns a value that doesn't necessarily match fileName.
String file = getFile();
if (file != null) {
... |
public class class_name {
public void push(long x) {
if (this.queueSize == this.maxSize) {
assert this.last == this.first;
this.sumOfQueue -= this.elems.get(this.last);
if ((++this.last) == this.maxSize)
this.last = 0;
} else
this.queueSize++;
this.sumOfQueue += x;
this.... | public class class_name {
public void push(long x) {
if (this.queueSize == this.maxSize) {
assert this.last == this.first; // depends on control dependency: [if], data = [none]
this.sumOfQueue -= this.elems.get(this.last); // depends on control dependency: [if], data = [none]
if ((++this.last) ==... |
public class class_name {
private void handleFragmentResponseMessage(FragmentResponseMessage message)
{
if (isFragmentMisrouted(message)){
m_mailbox.send(message.getDestinationSiteId(), message);
return;
}
final VoltTrace.TraceEventBatch traceLog = VoltTrace.log(Volt... | public class class_name {
private void handleFragmentResponseMessage(FragmentResponseMessage message)
{
if (isFragmentMisrouted(message)){
m_mailbox.send(message.getDestinationSiteId(), message); // depends on control dependency: [if], data = [none]
return; // depends on control dep... |
public class class_name {
protected String[] getSplitHosts(BlockLocation[] blkLocations,
long offset, long splitSize, NetworkTopology clusterMap)
throws IOException {
int startIndex = getBlockIndex(blkLocations, offset);
long bytesInThisBlock = blkLocations[startIndex].getOffset() +
... | public class class_name {
protected String[] getSplitHosts(BlockLocation[] blkLocations,
long offset, long splitSize, NetworkTopology clusterMap)
throws IOException {
int startIndex = getBlockIndex(blkLocations, offset);
long bytesInThisBlock = blkLocations[startIndex].getOffset() +
... |
public class class_name {
@PublicEvolving
public int getInteger(ConfigOption<Integer> configOption, int overrideDefault) {
Object o = getRawValueFromOption(configOption);
if (o == null) {
return overrideDefault;
}
return convertToInt(o, configOption.defaultValue());
} } | public class class_name {
@PublicEvolving
public int getInteger(ConfigOption<Integer> configOption, int overrideDefault) {
Object o = getRawValueFromOption(configOption);
if (o == null) {
return overrideDefault; // depends on control dependency: [if], data = [none]
}
return convertToInt(o, configOption.def... |
public class class_name {
private void fetchColumns() {
Vector temp = new Vector(20);
Vector tempType = new Vector(20);
try {
if (cConn == null) {
return;
}
if (dbmeta == null) {
dbmeta = cConn.getMetaData();
... | public class class_name {
private void fetchColumns() {
Vector temp = new Vector(20);
Vector tempType = new Vector(20);
try {
if (cConn == null) {
return; // depends on control dependency: [if], data = [none]
}
if (dbmeta == null) {
... |
public class class_name {
static String _getMimeType(String uriOrPath) {
String mime = MIME_MAP.get(__getExtension(uriOrPath));
if (mime == null) {
mime = DEFAULT_MIME;
}
return mime;
} } | public class class_name {
static String _getMimeType(String uriOrPath) {
String mime = MIME_MAP.get(__getExtension(uriOrPath));
if (mime == null) {
mime = DEFAULT_MIME; // depends on control dependency: [if], data = [none]
}
return mime;
} } |
public class class_name {
private Map<String, Object> getAllReflectedValues() {
Map<String, Object> res = new LinkedHashMap<>();
for (Map.Entry<MethodSymbol, Attribute> entry :
getAllValues().entrySet()) {
MethodSymbol meth = entry.getKey()... | public class class_name {
private Map<String, Object> getAllReflectedValues() {
Map<String, Object> res = new LinkedHashMap<>();
for (Map.Entry<MethodSymbol, Attribute> entry :
getAllValues().entrySet()) {
MethodSymbol meth = entry.getKey()... |
public class class_name {
private static boolean isLast(HttpMessage httpMessage) {
if (httpMessage instanceof FullHttpMessage) {
FullHttpMessage fullMessage = (FullHttpMessage) httpMessage;
if (fullMessage.trailingHeaders().isEmpty() && !fullMessage.content().isReadable()) {
... | public class class_name {
private static boolean isLast(HttpMessage httpMessage) {
if (httpMessage instanceof FullHttpMessage) {
FullHttpMessage fullMessage = (FullHttpMessage) httpMessage;
if (fullMessage.trailingHeaders().isEmpty() && !fullMessage.content().isReadable()) {
... |
public class class_name {
public void updateBinaryRepresenation() {
// check whether the binary state is in sync
final int firstModified = this.firstModifiedPos;
if (firstModified == Integer.MAX_VALUE) {
return;
}
final InternalDeSerializer serializer = this.serializer;
final int[] offsets = this.off... | public class class_name {
public void updateBinaryRepresenation() {
// check whether the binary state is in sync
final int firstModified = this.firstModifiedPos;
if (firstModified == Integer.MAX_VALUE) {
return; // depends on control dependency: [if], data = [none]
}
final InternalDeSerializer serializ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.