code stringlengths 130 281k | code_dependency stringlengths 182 306k |
|---|---|
public class class_name {
final int getSize(
final ClassWriter cw,
final byte[] code,
final int len,
final int maxStack,
final int maxLocals)
{
Attribute attr = this;
int size = 0;
while (attr != null) {
cw.newUTF8(attr.type);
... | public class class_name {
final int getSize(
final ClassWriter cw,
final byte[] code,
final int len,
final int maxStack,
final int maxLocals)
{
Attribute attr = this;
int size = 0;
while (attr != null) {
cw.newUTF8(attr.type); // depends o... |
public class class_name {
public static void init(final String appid,int initialDelay,int delay,String... types){
if(firestAppid == null){
firestAppid = appid;
}
for(final String type : types){
final String key = appid + KEY_JOIN + type;
if(scheduledExecutorService == null){
initScheduledExec... | public class class_name {
public static void init(final String appid,int initialDelay,int delay,String... types){
if(firestAppid == null){
firestAppid = appid;
// depends on control dependency: [if], data = [none]
}
for(final String type : types){
final String key = appid + KEY_JOIN + type;
if(sch... |
public class class_name {
@Override
@SuppressWarnings("unchecked")
public <E extends Entity> E getEntity(String attributeName, Class<E> clazz) {
Entity entity = delegate().getEntity(attributeName, clazz);
if (clazz.equals(FileMeta.class)) {
return entity != null ? (E) new FileMeta(newPretendingEntity... | public class class_name {
@Override
@SuppressWarnings("unchecked")
public <E extends Entity> E getEntity(String attributeName, Class<E> clazz) {
Entity entity = delegate().getEntity(attributeName, clazz);
if (clazz.equals(FileMeta.class)) {
return entity != null ? (E) new FileMeta(newPretendingEntity... |
public class class_name {
private void printMessage(final Throwable t) {
final String message = t.getMessage();
if (message != null && !message.trim().isEmpty()) {
printErrorMessage("Error: " + message);
}
} } | public class class_name {
private void printMessage(final Throwable t) {
final String message = t.getMessage();
if (message != null && !message.trim().isEmpty()) {
printErrorMessage("Error: " + message); // depends on control dependency: [if], data = [none]
}
} } |
public class class_name {
public int skipComment() {
char current = charAt(offset);
char next = charAt(offset + 1);
if (isSingleLineCommentBegin(current, next)) {
return skipSingleLineComment(COMMENT_BEGIN_SYMBOL_LENGTH);
} else if ('#' == current) {
return skipS... | public class class_name {
public int skipComment() {
char current = charAt(offset);
char next = charAt(offset + 1);
if (isSingleLineCommentBegin(current, next)) {
return skipSingleLineComment(COMMENT_BEGIN_SYMBOL_LENGTH); // depends on control dependency: [if], data = [none]
... |
public class class_name {
public void unusual() {
// Note that the first level does not have to be one
pyramid = FactoryPyramid.discreteGaussian(new int[]{2,6},-1,2,true, ImageType.single(imageType));
// Other kernels can also be used besides Gaussian
Kernel1D kernel;
if(GeneralizedImageOps.isFloatingPoint(... | public class class_name {
public void unusual() {
// Note that the first level does not have to be one
pyramid = FactoryPyramid.discreteGaussian(new int[]{2,6},-1,2,true, ImageType.single(imageType));
// Other kernels can also be used besides Gaussian
Kernel1D kernel;
if(GeneralizedImageOps.isFloatingPoint(... |
public class class_name {
private List<Resource> parseWarResources(Xpp3Dom warResourcesNode) {
List<Resource> resources = new ArrayList<Resource>();
Xpp3Dom[] resourceNodes = warResourcesNode.getChildren("resource");
for (Xpp3Dom resourceNode : resourceNodes) {
if (resourceNode == null || resourceNod... | public class class_name {
private List<Resource> parseWarResources(Xpp3Dom warResourcesNode) {
List<Resource> resources = new ArrayList<Resource>();
Xpp3Dom[] resourceNodes = warResourcesNode.getChildren("resource");
for (Xpp3Dom resourceNode : resourceNodes) {
if (resourceNode == null || resourceNod... |
public class class_name {
private String getSign(String body) {
String signNodeName = "<" + AlipayConstants.SIGN + ">";
String signEndNodeName = "</" + AlipayConstants.SIGN + ">";
int indexOfSignNode = body.indexOf(signNodeName);
int indexOfSignEndNode = body.indexOf(signEndNodeName);... | public class class_name {
private String getSign(String body) {
String signNodeName = "<" + AlipayConstants.SIGN + ">";
String signEndNodeName = "</" + AlipayConstants.SIGN + ">";
int indexOfSignNode = body.indexOf(signNodeName);
int indexOfSignEndNode = body.indexOf(signEndNodeName);... |
public class class_name {
private Double getValueOverBorders(GriddedTile griddedTile, TImage image,
Double[][] leftLastColumns, Double[][] topLeftRows,
Double[][] topRows, int x, int y) {
Double value = null;
// Only handle locations in the current tile, to the left, top left, or
// top tiles. Tiles are p... | public class class_name {
private Double getValueOverBorders(GriddedTile griddedTile, TImage image,
Double[][] leftLastColumns, Double[][] topLeftRows,
Double[][] topRows, int x, int y) {
Double value = null;
// Only handle locations in the current tile, to the left, top left, or
// top tiles. Tiles are p... |
public class class_name {
private RingbufferConfig getRingbufferConfig(RingbufferService service, ObjectNamespace ns) {
final String serviceName = ns.getServiceName();
if (RingbufferService.SERVICE_NAME.equals(serviceName)) {
return service.getRingbufferConfig(ns.getObjectName());
}... | public class class_name {
private RingbufferConfig getRingbufferConfig(RingbufferService service, ObjectNamespace ns) {
final String serviceName = ns.getServiceName();
if (RingbufferService.SERVICE_NAME.equals(serviceName)) {
return service.getRingbufferConfig(ns.getObjectName()); // depend... |
public class class_name {
static String readAnyField(Object obj, String ... names) {
try {
for (String name : names) {
try {
Field field = obj.getClass().getDeclaredField(name);
field.setAccessible(true);
return (String) fi... | public class class_name {
static String readAnyField(Object obj, String ... names) {
try {
for (String name : names) {
try {
Field field = obj.getClass().getDeclaredField(name);
field.setAccessible(true); // depends on control dependency: [try... |
public class class_name {
protected boolean processTopicTags(final TagProvider tagProvider, final ITopicNode specTopic, final TopicWrapper topic) {
LOG.debug("Processing topic tags");
boolean changed = false;
// Get the tags for the topic
final List<String> addTagNames = specTopic.getT... | public class class_name {
protected boolean processTopicTags(final TagProvider tagProvider, final ITopicNode specTopic, final TopicWrapper topic) {
LOG.debug("Processing topic tags");
boolean changed = false;
// Get the tags for the topic
final List<String> addTagNames = specTopic.getT... |
public class class_name {
@Override
public void close()
{
for (KestrelClientInfo info : this.clientInfoList)
{
info.closeClient();
}
// Closing the client connection causes all the open reliable reads to be aborted.
// Thus, clear our local buffer of these r... | public class class_name {
@Override
public void close()
{
for (KestrelClientInfo info : this.clientInfoList)
{
info.closeClient(); // depends on control dependency: [for], data = [info]
}
// Closing the client connection causes all the open reliable reads to be abor... |
public class class_name {
private Map<Integer, Integer> getNodeIdToPrimaryCount(Cluster cluster) {
Map<Integer, Integer> nodeIdToPrimaryCount = Maps.newHashMap();
for(Node node: cluster.getNodes()) {
nodeIdToPrimaryCount.put(node.getId(), node.getPartitionIds().size());
}
r... | public class class_name {
private Map<Integer, Integer> getNodeIdToPrimaryCount(Cluster cluster) {
Map<Integer, Integer> nodeIdToPrimaryCount = Maps.newHashMap();
for(Node node: cluster.getNodes()) {
nodeIdToPrimaryCount.put(node.getId(), node.getPartitionIds().size()); // depends on contro... |
public class class_name {
private static int findeol(byte b[], int pos, int len) {
int end = pos + len;
int i = pos;
while (i < end) {
if (b[i++] == '\n') {
return i - pos;
}
}
return -1;
} } | public class class_name {
private static int findeol(byte b[], int pos, int len) {
int end = pos + len;
int i = pos;
while (i < end) {
if (b[i++] == '\n') {
return i - pos; // depends on control dependency: [if], data = [none]
}
}
return -1;
} } |
public class class_name {
private void fakeServiceCall() {
poller.enablePoll();
Cache.getCache().invalidate(DATA_KEY);
new Thread() {
@Override
public void run() {
try {
Thread.sleep(SERVICE_TIME);
Cache.getCache().put(DATA_KEY, "SUCCESS!");
} catch (InterruptedException e) {
LOG.er... | public class class_name {
private void fakeServiceCall() {
poller.enablePoll();
Cache.getCache().invalidate(DATA_KEY);
new Thread() {
@Override
public void run() {
try {
Thread.sleep(SERVICE_TIME); // depends on control dependency: [try], data = [none]
Cache.getCache().put(DATA_KEY, "SUCCESS... |
public class class_name {
public void enable() {
updateState("up");
m_enabled = true;
// show the current file input field
if (m_fileInput != null) {
m_fileInput.getElement().getStyle().clearDisplay();
}
super.setTitle(m_title);
} } | public class class_name {
public void enable() {
updateState("up");
m_enabled = true;
// show the current file input field
if (m_fileInput != null) {
m_fileInput.getElement().getStyle().clearDisplay(); // depends on control dependency: [if], data = [none]
}
... |
public class class_name {
public Set<BuildConfiguration> getIndirectDependencies() {
Set<BuildConfiguration> indirectDependencies = new HashSet<BuildConfiguration>();
List<BuildConfiguration> configsToCheck = new ArrayList<BuildConfiguration>();
configsToCheck.addAll(getDependencies());
... | public class class_name {
public Set<BuildConfiguration> getIndirectDependencies() {
Set<BuildConfiguration> indirectDependencies = new HashSet<BuildConfiguration>();
List<BuildConfiguration> configsToCheck = new ArrayList<BuildConfiguration>();
configsToCheck.addAll(getDependencies());
... |
public class class_name {
public static Buckets fromCount(long start, long end, int count) {
checkTimeRange(start, end);
checkArgument(count > 0, "count is not positive: %s", count);
long quotient = (end - start) / count;
long remainder = (end - start) % count;
long step;
... | public class class_name {
public static Buckets fromCount(long start, long end, int count) {
checkTimeRange(start, end);
checkArgument(count > 0, "count is not positive: %s", count);
long quotient = (end - start) / count;
long remainder = (end - start) % count;
long step;
... |
public class class_name {
private void categories(RouteMeta routeMete) {
if (routeVerify(routeMete)) {
logger.info(">>> Start categories, group = " + routeMete.getGroup() + ", path = " + routeMete.getPath() + " <<<");
Set<RouteMeta> routeMetas = groupMap.get(routeMete.getGroup());
... | public class class_name {
private void categories(RouteMeta routeMete) {
if (routeVerify(routeMete)) {
logger.info(">>> Start categories, group = " + routeMete.getGroup() + ", path = " + routeMete.getPath() + " <<<"); // depends on control dependency: [if], data = [none]
Set<RouteMeta> ... |
public class class_name {
public void marshall(DescribeClustersRequest describeClustersRequest, ProtocolMarshaller protocolMarshaller) {
if (describeClustersRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMar... | public class class_name {
public void marshall(DescribeClustersRequest describeClustersRequest, ProtocolMarshaller protocolMarshaller) {
if (describeClustersRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMar... |
public class class_name {
boolean isDoubleAlias(String aliasName) {
CmsSiteMatcher testAlias = new CmsSiteMatcher(aliasName);
int count = 0;
for (Component c : m_aliases) {
if (c instanceof CmsRemovableFormRow<?>) {
String alName = (String)((CmsRemovableFormRow<? ex... | public class class_name {
boolean isDoubleAlias(String aliasName) {
CmsSiteMatcher testAlias = new CmsSiteMatcher(aliasName);
int count = 0;
for (Component c : m_aliases) {
if (c instanceof CmsRemovableFormRow<?>) {
String alName = (String)((CmsRemovableFormRow<? ex... |
public class class_name {
@Override
public String secureProtocol()
{
SSLSocket sslSocket = _sslSocket;
if (sslSocket == null) {
return super.secureProtocol();
}
SSLSession sslSession = sslSocket.getSession();
if (sslSession != null) {
return sslSession.getProtocol();
... | public class class_name {
@Override
public String secureProtocol()
{
SSLSocket sslSocket = _sslSocket;
if (sslSocket == null) {
return super.secureProtocol(); // depends on control dependency: [if], data = [none]
}
SSLSession sslSession = sslSocket.getSession();
if (sslSess... |
public class class_name {
public String addScreenParams(BasePanel screen, String strURL)
{
int iNumCols = screen.getSFieldCount();
for (int iIndex = 0; iIndex < iNumCols; iIndex++)
{
ScreenField sField = screen.getSField(iIndex);
boolean bPrintControl = true;
... | public class class_name {
public String addScreenParams(BasePanel screen, String strURL)
{
int iNumCols = screen.getSFieldCount();
for (int iIndex = 0; iIndex < iNumCols; iIndex++)
{
ScreenField sField = screen.getSField(iIndex);
boolean bPrintControl = true;
... |
public class class_name {
public TileResultSet queryByTileGrid(TileGrid tileGrid, long zoomLevel,
String orderBy) {
TileResultSet tileCursor = null;
if (tileGrid != null) {
StringBuilder where = new StringBuilder();
where.append(buildWhere(TileTable.COLUMN_ZOOM_LEVEL, zoomLevel));
where.append(" A... | public class class_name {
public TileResultSet queryByTileGrid(TileGrid tileGrid, long zoomLevel,
String orderBy) {
TileResultSet tileCursor = null;
if (tileGrid != null) {
StringBuilder where = new StringBuilder();
where.append(buildWhere(TileTable.COLUMN_ZOOM_LEVEL, zoomLevel)); // depends on contro... |
public class class_name {
@Override
public Object xpathQuery(String xpath, QName type, NamespaceContext nsContext)
{
try {
return super.xpathQuery(xpath, type, nsContext);
} catch (XPathExpressionException e) {
throw wrapExceptionAsRuntimeException(e);
}
} } | public class class_name {
@Override
public Object xpathQuery(String xpath, QName type, NamespaceContext nsContext)
{
try {
return super.xpathQuery(xpath, type, nsContext); // depends on control dependency: [try], data = [none]
} catch (XPathExpressionException e) {
throw... |
public class class_name {
public void setCellEditorValue(Object value) {
datePicker.clear();
if (value == null) {
return;
}
if (value instanceof LocalDate) {
LocalDate nativeValue = (LocalDate) value;
datePicker.setDate(nativeValue);
} else {
... | public class class_name {
public void setCellEditorValue(Object value) {
datePicker.clear();
if (value == null) {
return; // depends on control dependency: [if], data = [none]
}
if (value instanceof LocalDate) {
LocalDate nativeValue = (LocalDate) value;
... |
public class class_name {
@Override protected JobSpecSchedule doScheduleJob(JobSpec jobSpec, Runnable jobRunnable) {
// Build a data map that gets passed to the job
JobDataMap jobDataMap = new JobDataMap();
jobDataMap.put(JOB_SPEC_KEY, jobSpec);
jobDataMap.put(JOB_RUNNABLE_KEY, jobRunnable);
// B... | public class class_name {
@Override protected JobSpecSchedule doScheduleJob(JobSpec jobSpec, Runnable jobRunnable) {
// Build a data map that gets passed to the job
JobDataMap jobDataMap = new JobDataMap();
jobDataMap.put(JOB_SPEC_KEY, jobSpec);
jobDataMap.put(JOB_RUNNABLE_KEY, jobRunnable);
// B... |
public class class_name {
@Override
public boolean equalsIgnoringTypeParams(final TypeSignature other) {
if (this == other) {
return true;
}
if (!(other instanceof ArrayTypeSignature)) {
return false;
}
final ArrayTypeSignature o = (ArrayTypeSignature... | public class class_name {
@Override
public boolean equalsIgnoringTypeParams(final TypeSignature other) {
if (this == other) {
return true; // depends on control dependency: [if], data = [none]
}
if (!(other instanceof ArrayTypeSignature)) {
return false; // depends o... |
public class class_name {
protected synchronized void refreshServers() {
StringBuilder refreshResult = new StringBuilder();
Set<Server> availableReadServers = new HashSet<>();
Server[] newReadServers;
if (writeServer == null || !writeServer.isAvailable()) {
logger.debug("[r... | public class class_name {
protected synchronized void refreshServers() {
StringBuilder refreshResult = new StringBuilder();
Set<Server> availableReadServers = new HashSet<>();
Server[] newReadServers;
if (writeServer == null || !writeServer.isAvailable()) {
logger.debug("[r... |
public class class_name {
public void stop() {
if (!this.isActive) {
return;
}
cpuThread.shutdown();
try {
Thread.sleep(40);
} catch (InterruptedException e) {
}
for (int i = 0; i < taskQueues.length; i++)
taskQueues[i].clea... | public class class_name {
public void stop() {
if (!this.isActive) {
return; // depends on control dependency: [if], data = [none]
}
cpuThread.shutdown();
try {
Thread.sleep(40); // depends on control dependency: [try], data = [none]
} catch (Interrupte... |
public class class_name {
public Backbone compute(final Collection<Variable> variables, final BackboneType type) {
final boolean sat = solve(null) == Tristate.TRUE;
Backbone backbone = null;
if (sat) {
final List<Integer> relevantVarIndices = getRelevantVarIndices(variables);
... | public class class_name {
public Backbone compute(final Collection<Variable> variables, final BackboneType type) {
final boolean sat = solve(null) == Tristate.TRUE;
Backbone backbone = null;
if (sat) {
final List<Integer> relevantVarIndices = getRelevantVarIndices(variables);
... |
public class class_name {
@SuppressWarnings( "rawtypes" )
@Override
public ManagedConnection matchManagedConnections( Set connectionSet,
Subject subject,
ConnectionRequestInfo cxRequestInfo ) throws Reso... | public class class_name {
@SuppressWarnings( "rawtypes" )
@Override
public ManagedConnection matchManagedConnections( Set connectionSet,
Subject subject,
ConnectionRequestInfo cxRequestInfo ) throws Reso... |
public class class_name {
public MaterialSection getSectionByTitle(String title) {
for(MaterialSection section : sectionList) {
if(section.getTitle().equals(title)) {
return section;
}
}
for(MaterialSection section : bottomSectionList) {
if(... | public class class_name {
public MaterialSection getSectionByTitle(String title) {
for(MaterialSection section : sectionList) {
if(section.getTitle().equals(title)) {
return section; // depends on control dependency: [if], data = [none]
}
}
for(Material... |
public class class_name {
@Override
public VoidMessage takeMessage() {
if (threadingModel != ThreadingModel.SAME_THREAD) {
try {
return messages.take();
} catch (InterruptedException e) {
// probably we don't want to do anything here
r... | public class class_name {
@Override
public VoidMessage takeMessage() {
if (threadingModel != ThreadingModel.SAME_THREAD) {
try {
return messages.take(); // depends on control dependency: [try], data = [none]
} catch (InterruptedException e) {
// proba... |
public class class_name {
protected static URL getContributorURL(Contributor contributor, Log log) {
URL url = null;
if (contributor != null) {
String rawUrl = contributor.getUrl();
if (rawUrl != null && !EMPTY_STRING.equals(rawUrl)) {
try {
url = new URL(rawUrl);
} catch (Throwable exception) {... | public class class_name {
protected static URL getContributorURL(Contributor contributor, Log log) {
URL url = null;
if (contributor != null) {
String rawUrl = contributor.getUrl();
if (rawUrl != null && !EMPTY_STRING.equals(rawUrl)) {
try {
url = new URL(rawUrl); // depends on control dependency: [... |
public class class_name {
protected void handleOutParams(List<Param> paramList, final CallableStatement cs, Object parameter,
boolean functionCall) {
if (parameter == null){
return;
}
try {
final int start = functionCall ? 1 : 0;
for (int i... | public class class_name {
protected void handleOutParams(List<Param> paramList, final CallableStatement cs, Object parameter,
boolean functionCall) {
if (parameter == null){
return;
// depends on control dependency: [if], data = [none]
}
try {
final int... |
public class class_name {
public void handleEvent(final MasqueradeEvent b)
{
if (this.isConnectedToSelf(b.getClone()))
{
// At this point we will actually have two CallTrackers
// which we now need to merge into a single CallTracker.
CallTracker original = ... | public class class_name {
public void handleEvent(final MasqueradeEvent b)
{
if (this.isConnectedToSelf(b.getClone()))
{
// At this point we will actually have two CallTrackers
// which we now need to merge into a single CallTracker.
CallTracker original = ... |
public class class_name {
@Override
public void makeBuildVariables(AbstractBuild build, Map<String, String> variables) {
// global var/password pairs
MaskPasswordsConfig config = MaskPasswordsConfig.getInstance();
List<VarPasswordPair> globalVarPasswordPairs = config.getGlobalVarPasswor... | public class class_name {
@Override
public void makeBuildVariables(AbstractBuild build, Map<String, String> variables) {
// global var/password pairs
MaskPasswordsConfig config = MaskPasswordsConfig.getInstance();
List<VarPasswordPair> globalVarPasswordPairs = config.getGlobalVarPasswor... |
public class class_name {
@Nullable
private KeyType isKeyAccessMethod(int seen) {
if (seen == Const.INVOKEINTERFACE) {
String clsName = getClassConstantOperand();
if (HTTP_SESSION.equals(clsName)) {
String methodName = getNameConstantOperand();
if (GE... | public class class_name {
@Nullable
private KeyType isKeyAccessMethod(int seen) {
if (seen == Const.INVOKEINTERFACE) {
String clsName = getClassConstantOperand();
if (HTTP_SESSION.equals(clsName)) {
String methodName = getNameConstantOperand();
if (GE... |
public class class_name {
public static void verifyChain(List<X509Certificate> chain)
{
if (chain == null || chain.isEmpty())
throw new IllegalArgumentException("Must provide a chain that is non-null and non-empty");
for (int i = 0; i < chain.size(); i++)
{
final X509Certificate certificate = chain.get(i... | public class class_name {
public static void verifyChain(List<X509Certificate> chain)
{
if (chain == null || chain.isEmpty())
throw new IllegalArgumentException("Must provide a chain that is non-null and non-empty");
for (int i = 0; i < chain.size(); i++)
{
final X509Certificate certificate = chain.get(i... |
public class class_name {
public AwsSecurityFindingFilters withResourceDetailsOther(MapFilter... resourceDetailsOther) {
if (this.resourceDetailsOther == null) {
setResourceDetailsOther(new java.util.ArrayList<MapFilter>(resourceDetailsOther.length));
}
for (MapFilter ele : resource... | public class class_name {
public AwsSecurityFindingFilters withResourceDetailsOther(MapFilter... resourceDetailsOther) {
if (this.resourceDetailsOther == null) {
setResourceDetailsOther(new java.util.ArrayList<MapFilter>(resourceDetailsOther.length)); // depends on control dependency: [if], data = ... |
public class class_name {
public final void splitTo(AbstractNode<E> newNode, List<E> sorting, int splitPoint) {
assert (isLeaf() == newNode.isLeaf());
deleteAllEntries();
StringBuilder msg = LoggingConfiguration.DEBUG ? new StringBuilder(1000) : null;
for(int i = 0; i < splitPoint; i++) {
addEnt... | public class class_name {
public final void splitTo(AbstractNode<E> newNode, List<E> sorting, int splitPoint) {
assert (isLeaf() == newNode.isLeaf());
deleteAllEntries();
StringBuilder msg = LoggingConfiguration.DEBUG ? new StringBuilder(1000) : null;
for(int i = 0; i < splitPoint; i++) {
addEnt... |
public class class_name {
public void setDefault(final UUID _selectCmdUUID)
{
final UIMenuItem menuItem = getProvider().getRoots().next();
menuItem.setHeader(true);
boolean hasDefault = false;
for (final UIMenuItem childItem : menuItem.getChildren()) {
if (_selectCmdUUID... | public class class_name {
public void setDefault(final UUID _selectCmdUUID)
{
final UIMenuItem menuItem = getProvider().getRoots().next();
menuItem.setHeader(true);
boolean hasDefault = false;
for (final UIMenuItem childItem : menuItem.getChildren()) {
if (_selectCmdUUID... |
public class class_name {
static public PropertyDescriptor[] getPropertyDescriptors(Class<?> clazz) {
final String SETTER_PREFIX = "set";
final String GETTER_PREFIX = "get";
final int LEN_PREFIX = SETTER_PREFIX.length();
Map<String, PropertyDescriptor> map = new HashMap<String, PropertyDescriptor>();
... | public class class_name {
static public PropertyDescriptor[] getPropertyDescriptors(Class<?> clazz) {
final String SETTER_PREFIX = "set";
final String GETTER_PREFIX = "get";
final int LEN_PREFIX = SETTER_PREFIX.length();
Map<String, PropertyDescriptor> map = new HashMap<String, PropertyDescriptor>();
... |
public class class_name {
public String generateDigest(InputStream stream) {
MessageDigest digest = null;
try {
digest = MessageDigest.getInstance(DIGEST_ALGORITHM_SHA1);
} catch (NoSuchAlgorithmException ae) {
throw new BoxAPIException("Digest algorithm not found", ae);... | public class class_name {
public String generateDigest(InputStream stream) {
MessageDigest digest = null;
try {
digest = MessageDigest.getInstance(DIGEST_ALGORITHM_SHA1); // depends on control dependency: [try], data = [none]
} catch (NoSuchAlgorithmException ae) {
throw... |
public class class_name {
protected QName toQName(String namespaceUri, String qualifiedName) {
int idx = qualifiedName.indexOf(':');
if (idx == -1) {
return new QName(namespaceUri, qualifiedName);
} else {
String prefix = qualifiedName.substring(0, idx);
Stri... | public class class_name {
protected QName toQName(String namespaceUri, String qualifiedName) {
int idx = qualifiedName.indexOf(':');
if (idx == -1) {
return new QName(namespaceUri, qualifiedName); // depends on control dependency: [if], data = [none]
} else {
String pref... |
public class class_name {
public void modifyRequest(ResponseBuilder rb, SearchComponent who,
ShardRequest sreq) {
if ((sreq.purpose & ShardRequest.PURPOSE_GET_TOP_IDS) != 0) {
// do nothing
} else {
// remove stats for other requests
sreq.params.remove(PARAM_MTAS_STATS);
sreq.para... | public class class_name {
public void modifyRequest(ResponseBuilder rb, SearchComponent who,
ShardRequest sreq) {
if ((sreq.purpose & ShardRequest.PURPOSE_GET_TOP_IDS) != 0) {
// do nothing
} else {
// remove stats for other requests
sreq.params.remove(PARAM_MTAS_STATS); // depends on c... |
public class class_name {
public static String escapeForXML(final String content) {
if (content == null) return "";
/*
* Note: The following characters should be escaped: & < > " '
*
* However, all but ampersand pose issues when other elements are included in the title.
... | public class class_name {
public static String escapeForXML(final String content) {
if (content == null) return "";
/*
* Note: The following characters should be escaped: & < > " '
*
* However, all but ampersand pose issues when other elements are included in the title.
... |
public class class_name {
public static boolean checkAppBeforeAuth(Context context, String appKey, boolean alertUser) {
// Check if the app has set up its manifest properly.
Intent testIntent = new Intent(Intent.ACTION_VIEW);
String scheme = "db-" +appKey;
String uri = scheme + "://" + ... | public class class_name {
public static boolean checkAppBeforeAuth(Context context, String appKey, boolean alertUser) {
// Check if the app has set up its manifest properly.
Intent testIntent = new Intent(Intent.ACTION_VIEW);
String scheme = "db-" +appKey;
String uri = scheme + "://" + ... |
public class class_name {
public static double calc(String ... coords) {
try {
String [] array;
switch(coords.length) {
case 1:
array = Split.split(',',coords[0]);
if(array.length!=4)return -1;
return calc(
Double.parseDouble(array[0]),
Double.parseDouble(array[1]),
Double.parseDo... | public class class_name {
public static double calc(String ... coords) {
try {
String [] array;
switch(coords.length) {
case 1:
array = Split.split(',',coords[0]);
if(array.length!=4)return -1;
return calc(
Double.parseDouble(array[0]),
Double.parseDouble(array[1]),
Double.parseDo... |
public class class_name {
public Type glb(List<Type> ts) {
Type t1 = ts.head;
for (Type t2 : ts.tail) {
if (t1.isErroneous())
return t1;
t1 = glb(t1, t2);
}
return t1;
} } | public class class_name {
public Type glb(List<Type> ts) {
Type t1 = ts.head;
for (Type t2 : ts.tail) {
if (t1.isErroneous())
return t1;
t1 = glb(t1, t2); // depends on control dependency: [for], data = [t2]
}
return t1;
} } |
public class class_name {
@Override
public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
Tr.entry(tc, "checkClientTrusted");
extendedInfo = JSSEHelper.getInstance().getInb... | public class class_name {
@Override
public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
Tr.entry(tc, "checkClientTrusted");
extendedInfo = JSSEHelper.getInstance().getInb... |
public class class_name {
public static void setPreferredRadius(double radius) {
assert !Double.isNaN(radius);
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
prefs.putDouble("RADIUS", radius); //$NON-NLS-1$
try {
prefs.flush();
} catch (Back... | public class class_name {
public static void setPreferredRadius(double radius) {
assert !Double.isNaN(radius);
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
prefs.putDouble("RADIUS", radius); //$NON-NLS-1$ // depends on control dependency: [if], data... |
public class class_name {
public static Double getFirstScore(Set<Tuple> set) {
if (set == null || set.isEmpty()) {
return null;
}
Tuple tuple = set.iterator().next();
Double score = tuple.getScore();
return score;
} } | public class class_name {
public static Double getFirstScore(Set<Tuple> set) {
if (set == null || set.isEmpty()) {
return null;
// depends on control dependency: [if], data = [none]
}
Tuple tuple = set.iterator().next();
Double score = tuple.getScore();
return score;
} } |
public class class_name {
public static List<String> getAllAncestors(String eventPath) {
// check if the path is valid.
if (eventPath == null || !eventPath.startsWith(Path.SEPARATOR)) {
return null;
}
if (eventPath.equals(Path.SEPARATOR)) {
return Arrays.asList(Path.SEPARATOR);
}
... | public class class_name {
public static List<String> getAllAncestors(String eventPath) {
// check if the path is valid.
if (eventPath == null || !eventPath.startsWith(Path.SEPARATOR)) {
return null; // depends on control dependency: [if], data = [none]
}
if (eventPath.equals(Path.SEPARATOR))... |
public class class_name {
public List<Symbol> getAllSymbolsForType(JSType type) {
if (type == null) {
return ImmutableList.of();
}
UnionType unionType = type.toMaybeUnionType();
if (unionType != null) {
List<Symbol> result = new ArrayList<>(2);
for (JSType alt : unionType.getAlternat... | public class class_name {
public List<Symbol> getAllSymbolsForType(JSType type) {
if (type == null) {
return ImmutableList.of(); // depends on control dependency: [if], data = [none]
}
UnionType unionType = type.toMaybeUnionType();
if (unionType != null) {
List<Symbol> result = new ArrayLi... |
public class class_name {
private String combine(String parent, String child) {
if (parent.length() > 0) {
return parent.concat(".").concat(child);
} else {
return child;
}
} } | public class class_name {
private String combine(String parent, String child) {
if (parent.length() > 0) {
return parent.concat(".").concat(child); // depends on control dependency: [if], data = [none]
} else {
return child; // depends on control dependency: [if], data = [none]
}
} } |
public class class_name {
protected CmsLazyTreeItem createItem(final CmsSitemapEntryBean sitemapEntry) {
CmsDataValue dataValue = new CmsDataValue(
600,
3,
sitemapEntry.getSmallIconClasses(),
sitemapEntry.getDisplayName());
dataValue.setUnselectab... | public class class_name {
protected CmsLazyTreeItem createItem(final CmsSitemapEntryBean sitemapEntry) {
CmsDataValue dataValue = new CmsDataValue(
600,
3,
sitemapEntry.getSmallIconClasses(),
sitemapEntry.getDisplayName());
dataValue.setUnselectab... |
public class class_name {
public final boolean stop() {
if (booting || running) {
stopping = true;
booting = false;
onStopping();
return true;
} else {
return false;
}
} } | public class class_name {
public final boolean stop() {
if (booting || running) {
stopping = true; // depends on control dependency: [if], data = [none]
booting = false; // depends on control dependency: [if], data = [none]
onStopping(); // depends on control dependency: [i... |
public class class_name {
public static List<List<Term>> seg2sentence(String text)
{
List<List<Term>> resultList = new LinkedList<List<Term>>();
{
for (String sentence : SentencesUtil.toSentenceList(text))
{
resultList.add(segment(sentence));
}
... | public class class_name {
public static List<List<Term>> seg2sentence(String text)
{
List<List<Term>> resultList = new LinkedList<List<Term>>();
{
for (String sentence : SentencesUtil.toSentenceList(text))
{
resultList.add(segment(sentence)); // depends on co... |
public class class_name {
@Deprecated
public void addLibrary(Class<?> clazz, int port) {
if (!server.isStopped()) // old behavior
throw new IllegalStateException("Cannot add a library once the server is started");
if (connector.getPort() != 0 && connector.getPort() != port) {
... | public class class_name {
@Deprecated
public void addLibrary(Class<?> clazz, int port) {
if (!server.isStopped()) // old behavior
throw new IllegalStateException("Cannot add a library once the server is started");
if (connector.getPort() != 0 && connector.getPort() != port) {
... |
public class class_name {
private ExtractionInfo extractMultilineTextualBlock(
JsDocToken token, WhitespaceOption option, boolean includeAnnotations) {
if (token == JsDocToken.EOC || token == JsDocToken.EOL || token == JsDocToken.EOF) {
return new ExtractionInfo("", token);
}
return extractMult... | public class class_name {
private ExtractionInfo extractMultilineTextualBlock(
JsDocToken token, WhitespaceOption option, boolean includeAnnotations) {
if (token == JsDocToken.EOC || token == JsDocToken.EOL || token == JsDocToken.EOF) {
return new ExtractionInfo("", token); // depends on control depend... |
public class class_name {
public static OptionalThing<Classification> findByCode(Class<?> cdefType, Object code) {
assertArgumentNotNull("cdefType", cdefType);
assertArgumentNotNull("code", code);
// #hope switch to nativeFindByCode() in future (can be over DBFlute-1.1.1) by jflute
fin... | public class class_name {
public static OptionalThing<Classification> findByCode(Class<?> cdefType, Object code) {
assertArgumentNotNull("cdefType", cdefType);
assertArgumentNotNull("code", code);
// #hope switch to nativeFindByCode() in future (can be over DBFlute-1.1.1) by jflute
fin... |
public class class_name {
@Override
protected boolean doEvaluate(String line)
{
line = line.substring(line.indexOf(' ') + 1);
try
{
println(line + " = " + interpreter.evaluate(line, getFrame()));
} catch (ParserException e)
{
println("Syntax: " + e);
} catch (ContextException e)
{
println("Ru... | public class class_name {
@Override
protected boolean doEvaluate(String line)
{
line = line.substring(line.indexOf(' ') + 1);
try
{
println(line + " = " + interpreter.evaluate(line, getFrame())); // depends on control dependency: [try], data = [none]
} catch (ParserException e)
{
println("Syntax: " ... |
public class class_name {
private Optional<ThriftTableMetadata> getTableMetadataInternal(SchemaTableName schemaTableName)
{
requireNonNull(schemaTableName, "schemaTableName is null");
PrestoThriftNullableTableMetadata thriftTableMetadata = getTableMetadata(schemaTableName);
if (thriftTableM... | public class class_name {
private Optional<ThriftTableMetadata> getTableMetadataInternal(SchemaTableName schemaTableName)
{
requireNonNull(schemaTableName, "schemaTableName is null");
PrestoThriftNullableTableMetadata thriftTableMetadata = getTableMetadata(schemaTableName);
if (thriftTableM... |
public class class_name {
private void ensureDefaultOccurElements(IChemObjectBuilder builder) {
if (mfRange == null) {
String[] elements = new String[]{"C", "H", "O", "N", "Si", "P", "S", "F", "Cl", "Br", "I", "Sn", "B", "Pb",
"Tl", "Ba", "In", "Pd", "Pt", "Os", "Ag", "Zr", "Se"... | public class class_name {
private void ensureDefaultOccurElements(IChemObjectBuilder builder) {
if (mfRange == null) {
String[] elements = new String[]{"C", "H", "O", "N", "Si", "P", "S", "F", "Cl", "Br", "I", "Sn", "B", "Pb",
"Tl", "Ba", "In", "Pd", "Pt", "Os", "Ag", "Zr", "Se"... |
public class class_name {
public void marshall(LogStream logStream, ProtocolMarshaller protocolMarshaller) {
if (logStream == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(logStream.getLogStreamNam... | public class class_name {
public void marshall(LogStream logStream, ProtocolMarshaller protocolMarshaller) {
if (logStream == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(logStream.getLogStreamNam... |
public class class_name {
private void showSelect(boolean show) {
if (show) {
m_main.addStyleName(I_CmsLayoutBundle.INSTANCE.selectAreaCss().showSelect());
return;
}
m_main.removeStyleName(I_CmsLayoutBundle.INSTANCE.selectAreaCss().showSelect());
} } | public class class_name {
private void showSelect(boolean show) {
if (show) {
m_main.addStyleName(I_CmsLayoutBundle.INSTANCE.selectAreaCss().showSelect()); // depends on control dependency: [if], data = [none]
return; // depends on control dependency: [if], data = [none]
}
... |
public class class_name {
public static <E extends Extension> IterableResult<E> appendSearchResults(IterableResult<E> previousSearchResult,
IterableResult<E> result)
{
AggregatedIterableResult<E> newResult;
if (previousSearchResult instanceof AggregatedIterableResult) {
newResu... | public class class_name {
public static <E extends Extension> IterableResult<E> appendSearchResults(IterableResult<E> previousSearchResult,
IterableResult<E> result)
{
AggregatedIterableResult<E> newResult;
if (previousSearchResult instanceof AggregatedIterableResult) {
newResu... |
public class class_name {
public <T> T get(Key<T> key) {
checkState(ht);
Object o = ht.get(key);
if (o instanceof Factory<?>) {
Factory<?> fac = (Factory<?>)o;
o = fac.make(this);
if (o instanceof Factory<?>)
throw new AssertionError("T extend... | public class class_name {
public <T> T get(Key<T> key) {
checkState(ht);
Object o = ht.get(key);
if (o instanceof Factory<?>) {
Factory<?> fac = (Factory<?>)o;
o = fac.make(this); // depends on control dependency: [if], data = [)]
if (o instanceof Factory<?>)... |
public class class_name {
private void loadYAMLResource(final File file) {
BufferedReader reader = null;
try {
reader = new BufferedReader(new InputStreamReader(new FileInputStream(file)));
String line = null;
while ((line = reader.readLine()) != null) {
// 1. check for comments
String[] commen... | public class class_name {
private void loadYAMLResource(final File file) {
BufferedReader reader = null;
try {
reader = new BufferedReader(new InputStreamReader(new FileInputStream(file))); // depends on control dependency: [try], data = [none]
String line = null;
while ((line = reader.readLine()) != nu... |
public class class_name {
@SuppressWarnings("unchecked")
public <T> T[] toArray(T[] a) {
if (a.length < events.size()) {
a = (T[]) java.lang.reflect.Array.newInstance(a.getClass()
.getComponentType(), events.size());
}
for (int i = 0; i < events.size(); i++) {
try {
a[i] = (T) events.get(i);
}... | public class class_name {
@SuppressWarnings("unchecked")
public <T> T[] toArray(T[] a) {
if (a.length < events.size()) {
a = (T[]) java.lang.reflect.Array.newInstance(a.getClass()
.getComponentType(), events.size()); // depends on control dependency: [if], data = [none]
}
for (int i = 0; i < events.size... |
public class class_name {
public int getMessageSetSerializedSize() {
int size = 0;
for (int i = 0; i < fields.getNumArrayEntries(); i++) {
size += getMessageSetSerializedSize(fields.getArrayEntryAt(i));
}
for (final Map.Entry<FieldDescriptorType, Object> entry :
fields.getOverflowEnt... | public class class_name {
public int getMessageSetSerializedSize() {
int size = 0;
for (int i = 0; i < fields.getNumArrayEntries(); i++) {
size += getMessageSetSerializedSize(fields.getArrayEntryAt(i)); // depends on control dependency: [for], data = [i]
}
for (final Map.Entry<FieldDescriptorType... |
public class class_name {
protected void addBehaviorListener(BehaviorListener listener) {
if (listener == null) {
throw new NullPointerException();
}
if (listeners == null) {
//noinspection CollectionWithoutInitialCapacity
listeners = new ArrayList<BehaviorL... | public class class_name {
protected void addBehaviorListener(BehaviorListener listener) {
if (listener == null) {
throw new NullPointerException();
}
if (listeners == null) {
//noinspection CollectionWithoutInitialCapacity
listeners = new ArrayList<BehaviorL... |
public class class_name {
public static <T> List<T> getServices(final Class<T> intf)
{
Objects.requireNonNull(intf);
List<T> ret = new LinkedList<>();
for (final T t : ServiceLoader.load(intf)) {
ret.add(t);
}
return ret;
} } | public class class_name {
public static <T> List<T> getServices(final Class<T> intf)
{
Objects.requireNonNull(intf);
List<T> ret = new LinkedList<>();
for (final T t : ServiceLoader.load(intf)) {
ret.add(t); // depends on control dependency: [for], data = [t]
}
r... |
public class class_name {
public void marshall(DataPoint dataPoint, ProtocolMarshaller protocolMarshaller) {
if (dataPoint == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(dataPoint.getTimestamp(),... | public class class_name {
public void marshall(DataPoint dataPoint, ProtocolMarshaller protocolMarshaller) {
if (dataPoint == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(dataPoint.getTimestamp(),... |
public class class_name {
public void paintAndClear (Graphics2D gfx)
{
int icount = _items.size();
for (int ii = 0; ii < icount; ii++) {
DirtyItem item = _items.get(ii);
item.paint(gfx);
item.clear();
_freelist.add(item);
}
_items.clea... | public class class_name {
public void paintAndClear (Graphics2D gfx)
{
int icount = _items.size();
for (int ii = 0; ii < icount; ii++) {
DirtyItem item = _items.get(ii);
item.paint(gfx); // depends on control dependency: [for], data = [none]
item.clear(); // depe... |
public class class_name {
public java.util.List<VpcAttachment> getVpcAttachments() {
if (vpcAttachments == null) {
vpcAttachments = new com.amazonaws.internal.SdkInternalList<VpcAttachment>();
}
return vpcAttachments;
} } | public class class_name {
public java.util.List<VpcAttachment> getVpcAttachments() {
if (vpcAttachments == null) {
vpcAttachments = new com.amazonaws.internal.SdkInternalList<VpcAttachment>(); // depends on control dependency: [if], data = [none]
}
return vpcAttachments;
} } |
public class class_name {
public boolean answerCallbackQuery(String callbackQueryId, CallbackQueryResponse callbackQueryResponse) {
if(callbackQueryId != null && callbackQueryResponse.getText() != null) {
HttpResponse<String> response;
JSONObject jsonResponse;
try {
... | public class class_name {
public boolean answerCallbackQuery(String callbackQueryId, CallbackQueryResponse callbackQueryResponse) {
if(callbackQueryId != null && callbackQueryResponse.getText() != null) {
HttpResponse<String> response;
JSONObject jsonResponse;
try {
... |
public class class_name {
public long getEvitableBytes() {
long bytes = 0;
for (BlockMeta blockMeta : mDir.getBlocks()) {
long blockId = blockMeta.getBlockId();
if (mManagerView.isBlockEvictable(blockId)) {
bytes += blockMeta.getBlockSize();
}
}
return bytes;
} } | public class class_name {
public long getEvitableBytes() {
long bytes = 0;
for (BlockMeta blockMeta : mDir.getBlocks()) {
long blockId = blockMeta.getBlockId();
if (mManagerView.isBlockEvictable(blockId)) {
bytes += blockMeta.getBlockSize(); // depends on control dependency: [if], data = [n... |
public class class_name {
public static List<File> getClusterLexiconFiles(final String clusterPath) {
final List<File> clusterLexicons = new ArrayList<File>();
final String[] clusterPaths = clusterPath.split(",");
for (final String clusterName : clusterPaths) {
clusterLexicons.add(new File(clusterNam... | public class class_name {
public static List<File> getClusterLexiconFiles(final String clusterPath) {
final List<File> clusterLexicons = new ArrayList<File>();
final String[] clusterPaths = clusterPath.split(",");
for (final String clusterName : clusterPaths) {
clusterLexicons.add(new File(clusterNam... |
public class class_name {
public static String nativeEventsTableName(final StreamId streamId) {
// User defined ID
if (streamId instanceof JpaStreamId) {
final JpaStreamId jpaId = (JpaStreamId) streamId;
return jpaId.getNativeTableName();
}
// Default ID
... | public class class_name {
public static String nativeEventsTableName(final StreamId streamId) {
// User defined ID
if (streamId instanceof JpaStreamId) {
final JpaStreamId jpaId = (JpaStreamId) streamId;
return jpaId.getNativeTableName(); // depends on control dependency: [if], ... |
public class class_name {
private IterationModels computeIterationModels(final IterationWhiteSpaceHandling iterationWhiteSpaceHandling) {
/*
* Nothing to iterate
*/
if (iterationWhiteSpaceHandling == IterationWhiteSpaceHandling.ZERO_ITER) {
return IterationModels.EMPTY;
... | public class class_name {
private IterationModels computeIterationModels(final IterationWhiteSpaceHandling iterationWhiteSpaceHandling) {
/*
* Nothing to iterate
*/
if (iterationWhiteSpaceHandling == IterationWhiteSpaceHandling.ZERO_ITER) {
return IterationModels.EMPTY; /... |
public class class_name {
public void addAll( List<T> list ) {
if( list.isEmpty() )
return;
Element<T> a = requestNew();
a.object = list.get(0);
if( first == null ) {
first = a;
} else if( last != null ) {
last.next = a;
a.previous = last;
}
for (int i = 1; i < list.size(); i++) {
Eleme... | public class class_name {
public void addAll( List<T> list ) {
if( list.isEmpty() )
return;
Element<T> a = requestNew();
a.object = list.get(0);
if( first == null ) {
first = a; // depends on control dependency: [if], data = [none]
} else if( last != null ) {
last.next = a; // depends on control d... |
public class class_name {
private void processToUnicode(){
PdfObject toUni = fontDic.get(PdfName.TOUNICODE);
if (toUni != null){
try {
byte[] touni = PdfReader.getStreamBytes((PRStream)PdfReader.getPdfObjectRelease(toUni));
... | public class class_name {
private void processToUnicode(){
PdfObject toUni = fontDic.get(PdfName.TOUNICODE);
if (toUni != null){
try {
byte[] touni = PdfReader.getStreamBytes((PRStream)PdfReader.getPdfObjectRelease(toUni));
... |
public class class_name {
public EqualsVerifierReport report() {
try {
performVerification();
return EqualsVerifierReport.SUCCESS;
}
catch (MessagingException e) {
return new EqualsVerifierReport(false, buildErrorMessage(e.getDescription()), e);
}
... | public class class_name {
public EqualsVerifierReport report() {
try {
performVerification(); // depends on control dependency: [try], data = [none]
return EqualsVerifierReport.SUCCESS; // depends on control dependency: [try], data = [none]
}
catch (MessagingException e)... |
public class class_name {
private String ifNull(int rowIndex){
if(params.length != 2){
throw new IllegalArgumentException("Wrong number of Parameters for if null expression");
}
final RecordList.Record currentRecord = recordList.getRecords().get(rowIndex);
final String fie... | public class class_name {
private String ifNull(int rowIndex){
if(params.length != 2){
throw new IllegalArgumentException("Wrong number of Parameters for if null expression");
}
final RecordList.Record currentRecord = recordList.getRecords().get(rowIndex);
final String fie... |
public class class_name {
JavaArchive createWarpArchive() {
JavaArchive archive = ShrinkWrap.create(JavaArchive.class, "arquillian-warp.jar");
// API
archive.addClass(Inspection.class);
archive.addClasses(BeforeServlet.class, AfterServlet.class);
for (String packageName : REQU... | public class class_name {
JavaArchive createWarpArchive() {
JavaArchive archive = ShrinkWrap.create(JavaArchive.class, "arquillian-warp.jar");
// API
archive.addClass(Inspection.class);
archive.addClasses(BeforeServlet.class, AfterServlet.class);
for (String packageName : REQU... |
public class class_name {
protected void updateActionForInterimTarget(Action action) {
// find an interim target position
PointF scrollVector = computeScrollVectorForPosition(getTargetPosition());
if (scrollVector == null || (scrollVector.x == 0 && scrollVector.y == 0)) {
Log.e(TAG,... | public class class_name {
protected void updateActionForInterimTarget(Action action) {
// find an interim target position
PointF scrollVector = computeScrollVectorForPosition(getTargetPosition());
if (scrollVector == null || (scrollVector.x == 0 && scrollVector.y == 0)) {
Log.e(TAG,... |
public class class_name {
public static JoinNode reconstructJoinTreeFromSubTrees(List<JoinNode> subTrees) {
if (subTrees == null || subTrees.isEmpty()) {
return null;
}
// Reconstruct the tree. The first element is the first sub-tree and so on
JoinNode joinNode = subTrees.ge... | public class class_name {
public static JoinNode reconstructJoinTreeFromSubTrees(List<JoinNode> subTrees) {
if (subTrees == null || subTrees.isEmpty()) {
return null; // depends on control dependency: [if], data = [none]
}
// Reconstruct the tree. The first element is the first sub-... |
public class class_name {
public String getHostName() {
String hostName = mHostName;
try {
// ZAP: fixed cases, where host name is null
hostName = ((mUri.getHost() != null) ? mUri.getHost() : mHostName);
} catch (URIException e) {
if (log.... | public class class_name {
public String getHostName() {
String hostName = mHostName;
try {
// ZAP: fixed cases, where host name is null
hostName = ((mUri.getHost() != null) ? mUri.getHost() : mHostName);
// depends on control dependency: [try], data = [none]
... |
public class class_name {
public void enter(@NonNull ID id, boolean withAnimation) {
if (GestureDebug.isDebugAnimator()) {
Log.d(TAG, "Enter requested for " + id + ", with animation = " + withAnimation);
}
enterWithAnimation = withAnimation;
request(id);
} } | public class class_name {
public void enter(@NonNull ID id, boolean withAnimation) {
if (GestureDebug.isDebugAnimator()) {
Log.d(TAG, "Enter requested for " + id + ", with animation = " + withAnimation); // depends on control dependency: [if], data = [none]
}
enterWithAnimation = w... |
public class class_name {
public static String getTopActivityPackageName(Context context) {
ComponentName activity = getTopActivity(context);
if (activity == null) {
return null;
}
return activity.getPackageName();
} } | public class class_name {
public static String getTopActivityPackageName(Context context) {
ComponentName activity = getTopActivity(context);
if (activity == null) {
return null; // depends on control dependency: [if], data = [none]
}
return activity.getPackageName();
} } |
public class class_name {
public synchronized Set<Service> getServices() {
checkInitialized();
if (legacyChanged || servicesChanged) {
serviceSet = null;
}
if (serviceSet == null) {
ensureLegacyParsed();
Set<Service> set = new LinkedHashSet<>();
... | public class class_name {
public synchronized Set<Service> getServices() {
checkInitialized();
if (legacyChanged || servicesChanged) {
serviceSet = null; // depends on control dependency: [if], data = [none]
}
if (serviceSet == null) {
ensureLegacyParsed(); // de... |
public class class_name {
private void initExpressions()
{
expressions = new LinkedList<>();
for (UriTemplateComponent c : components)
{
if (c instanceof Expression)
{
expressions.add((Expression) c);
}
}
} } | public class class_name {
private void initExpressions()
{
expressions = new LinkedList<>();
for (UriTemplateComponent c : components)
{
if (c instanceof Expression)
{
expressions.add((Expression) c); // depends on control dependency: [if], data = [no... |
public class class_name {
char generateStandInFor(Object obj) {
// assert(obj != null);
// Look up previous stand-in, if any. This is a short list
// (typical n is 0, 1, or 2); linear search is optimal.
for (int i=0; i<variablesVector.size(); ++i) {
if (variablesVector.get... | public class class_name {
char generateStandInFor(Object obj) {
// assert(obj != null);
// Look up previous stand-in, if any. This is a short list
// (typical n is 0, 1, or 2); linear search is optimal.
for (int i=0; i<variablesVector.size(); ++i) {
if (variablesVector.get... |
public class class_name {
public Matrix plus(Matrix B)
{
checkMatrixDimensions(B);
Matrix X = new Matrix(m, n);
double[][] C = X.getArray();
for (int i = 0; i < m; i++)
{
for (int j = 0; j < n; j++)
{
C[i][j] = A[i][j] + B.A[i][j];
... | public class class_name {
public Matrix plus(Matrix B)
{
checkMatrixDimensions(B);
Matrix X = new Matrix(m, n);
double[][] C = X.getArray();
for (int i = 0; i < m; i++)
{
for (int j = 0; j < n; j++)
{
C[i][j] = A[i][j] + B.A[i][j]; // ... |
public class class_name {
protected IObjectPickler getCustomPickler(Class<?> t) {
IObjectPickler pickler = customPicklers.get(t);
if(pickler!=null) {
return pickler; // exact match
}
// check if there's a custom pickler registered for an interface or abstract base class
// that this object implements or... | public class class_name {
protected IObjectPickler getCustomPickler(Class<?> t) {
IObjectPickler pickler = customPicklers.get(t);
if(pickler!=null) {
return pickler; // exact match // depends on control dependency: [if], data = [none]
}
// check if there's a custom pickler registered for an interface or a... |
public class class_name {
public <R> BaasResult<R> execute(Task<R> request) {
try {
R r = request.asyncCall();
return BaasResult.success(r);
} catch (BaasException e) {
return BaasResult.failure(e);
}
} } | public class class_name {
public <R> BaasResult<R> execute(Task<R> request) {
try {
R r = request.asyncCall();
return BaasResult.success(r); // depends on control dependency: [try], data = [none]
} catch (BaasException e) {
return BaasResult.failure(e);
} // ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.