idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,424,621 | public double compare(Record r1, Record r2) {<NEW_LINE>comparisons++;<NEW_LINE>double prob = 0.5;<NEW_LINE>for (String propname : r1.getProperties()) {<NEW_LINE>Property <MASK><NEW_LINE>if (prop == null)<NEW_LINE>// means the property is unknown<NEW_LINE>continue;<NEW_LINE>if (prop.isIdProperty() || prop.isIgnoreProper... | prop = config.getPropertyByName(propname); |
1,204,919 | public Credentials unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>Credentials credentials = new Credentials();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE>targetDepth += 1;<NEW_LINE>whil... | ().unmarshall(context)); |
565,401 | public List<DataSetTableUnionDTO> listByTableId(String tableId) {<NEW_LINE>List<DataSetTableUnionDTO> sourceList = extDatasetTableUnionMapper.selectBySourceTableId(tableId);<NEW_LINE>List<DataSetTableUnionDTO> <MASK><NEW_LINE>sourceList.addAll(targetList.stream().map(ele -> {<NEW_LINE>DataSetTableUnionDTO dto = new Dat... | targetList = extDatasetTableUnionMapper.selectByTargetTableId(tableId); |
686,819 | public User userGet() throws TimeoutException, ExecutionException, InterruptedException, ApiException {<NEW_LINE>Object postBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String path = "/user";<NEW_LINE>// query params<NEW_LINE>List<Pair> queryParams = new ArrayList<Pair>();<NEW_LINE>// header params<N... | (VolleyError) ex.getCause(); |
214,701 | private static InterruptSignalHandler captureSigint(@Nullable String slowInterruptMessage) {<NEW_LINE>Thread mainThread = Thread.currentThread();<NEW_LINE>AtomicInteger numInterrupts = new AtomicInteger();<NEW_LINE>Runnable interruptWatcher = () -> {<NEW_LINE>int count = 0;<NEW_LINE>// Not an actual infinite loop becau... | OutErr.SYSTEM_OUT_ERR.printErrLn("Bazel received an interrupt"); |
1,096,344 | private void customizeSearchResourceEncryptionKey(ClassCustomization keyCustomization, ClassCustomization credentialCustomization) {<NEW_LINE>keyCustomization.removeMethod("getAccessCredentials");<NEW_LINE>String setterReturnJavadoc = keyCustomization.getMethod("setAccessCredentials").getJavadoc().getReturn();<NEW_LINE... | ("getApplicationSecret").getJavadoc()); |
1,389,069 | public Iterator<String> iterateNames(final ConfigSourceInterceptorContext context) {<NEW_LINE>final Set<String> names = new HashSet<>();<NEW_LINE>final Iterator<String> namesIterator = context.iterateNames();<NEW_LINE>while (namesIterator.hasNext()) {<NEW_LINE>final String name = namesIterator.next();<NEW_LINE>names.ad... | (GLOBAL_PROPERTIES_INVERSE.get(name)); |
78,210 | private static SolidityContract submitAllContracts(String main, List<String> compiledContractDirs, EasyBlockchain init) throws IOException {<NEW_LINE><MASK><NEW_LINE>AtomicReference<SolidityContract> res = new AtomicReference<>();<NEW_LINE>compiledContractDirs.stream().map(s -> Paths.get(s)).filter(p -> Files.isDirecto... | System.out.print("Submitting contracts... "); |
1,487,007 | public void paint(final Graphics g) {<NEW_LINE>super.paint(g);<NEW_LINE>if (!isEnabled()) {<NEW_LINE><MASK><NEW_LINE>}<NEW_LINE>// 2nd color<NEW_LINE>g.setColor(border1color);<NEW_LINE>g.drawRect(getWidth() - 3 - RECT_LENGTH, getHeight() - 3 - RECT_LENGTH, RECT_LENGTH, RECT_LENGTH);<NEW_LINE>g.setColor(border2color);<N... | g.setXORMode(Color.GRAY); |
1,530,644 | private float computeTextWidth(@NotNull Font font, final boolean mainTextOnly) {<NEW_LINE>float result = 0;<NEW_LINE>final int baseSize = font.getSize();<NEW_LINE>boolean wasSmaller = false;<NEW_LINE>for (int i = 0; i < myAttributes.size(); i++) {<NEW_LINE>final SimpleTextAttributes <MASK><NEW_LINE>final boolean isSmal... | attributes = myAttributes.get(i); |
710,160 | private void processLabel(DIEAggregate diea) {<NEW_LINE>if (!shouldProcess(diea)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>String <MASK><NEW_LINE>if (name != null && diea.hasAttribute(DW_AT_low_pc)) {<NEW_LINE>Address address = toAddr(diea.getLowPC(0));<NEW_LINE>if (address.getOffset() != 0) {<NEW_LINE>try {<NEW_LINE>Sym... | name = prog.getEntryName(diea); |
1,822,653 | private // represents the PREV operation<NEW_LINE>CEPLiteral prev(CEPOperation opr1, CEPLiteral opr2, EventPointer curPointer, Event curEvent, Event inputEvent) {<NEW_LINE>if (opr1.getClass() != CEPFieldRef.class) {<NEW_LINE>throw new IllegalStateException("the first argument of the PREV operation should be a field ref... | .toCEPLiteral((CEPFieldRef) opr1); |
665,183 | public CompletionStage<Object> resolve(EvalContext context) {<NEW_LINE>JsonObject jsonObject = (JsonObject) context.getBase();<NEW_LINE>switch(context.getName()) {<NEW_LINE>case "fieldNames":<NEW_LINE>case "fields":<NEW_LINE>return CompletableFuture.completedFuture(jsonObject.fieldNames());<NEW_LINE>case "size":<NEW_LI... | completedFuture(jsonObject.isEmpty()); |
1,654,988 | private Notification buildSummaryNotification() {<NEW_LINE>final int notices = currentlyNotifiedNotices.size();<NEW_LINE>final String projectName = currentlyNotifiedNotices.get(0).getProjectName();<NEW_LINE>final int icon = R.drawable.ic_boinc;<NEW_LINE>final int smallIcon = Build.VERSION.SDK_INT < Build.VERSION_CODES.... | .getBitmapFromVectorDrawable(context, icon)); |
1,631,946 | private void shutdownJobSchedulers() {<NEW_LINE>Map<String, JobScheduler> schdMap = JobRegistry.<MASK><NEW_LINE>if (MapUtils.isEmpty(schdMap)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>long startTime = System.currentTimeMillis();<NEW_LINE>List<Future<?>> futures = new ArrayList<>();<NEW_LINE>Iterator<String> it = schdMap.... | getSchedulerMap().get(executorName); |
74,667 | protected UserProfileMetadata configureUserProfile(UserProfileMetadata metadata, KeycloakSession session) {<NEW_LINE><MASK><NEW_LINE>UserProfileMetadata decoratedMetadata = metadata.clone();<NEW_LINE>if (!isEnabled(session)) {<NEW_LINE>if (!context.equals(UserProfileContext.USER_API) && !context.equals(UserProfileConte... | UserProfileContext context = metadata.getContext(); |
90,466 | public DescribeReturnShippingLabelResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeReturnShippingLabelResult describeReturnShippingLabelResult = new DescribeReturnShippingLabelResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth... | String currentParentElement = context.getCurrentParentElement(); |
399,118 | // Cleanup: private<NEW_LINE>public ContentValues prepareChannelUserMapperValues(ChannelUserMapper channelUserMapper) {<NEW_LINE>ContentValues contentValues = new ContentValues();<NEW_LINE>if (channelUserMapper != null) {<NEW_LINE>if (channelUserMapper.getKey() != null) {<NEW_LINE>contentValues.put(MobiComDatabaseHelpe... | USERID, channelUserMapper.getUserKey()); |
948,541 | public Document createComponentXML() throws ParserConfigurationException {<NEW_LINE>DocumentBuilderFactory fact = DocumentBuilderFactory.newInstance();<NEW_LINE>fact.setNamespaceAware(true);<NEW_LINE>Document doc = fact.newDocumentBuilder().newDocument();<NEW_LINE>Element root = (Element) doc.appendChild(doc.createElem... | desc.setAttribute("version", version); |
420,933 | /* (non-Javadoc)<NEW_LINE>* @see android.app.Dialog#onCreate(android.os.Bundle)<NEW_LINE>*/<NEW_LINE>@Override<NEW_LINE>protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>setTitle(R.string.repeater_dialog_title);<NEW_LINE>setContentView(R.layout.repeater_dialog);<... | R.string.repeater_caption))); |
1,610,960 | public static DescribeImageSharePermissionResponse unmarshall(DescribeImageSharePermissionResponse describeImageSharePermissionResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeImageSharePermissionResponse.setRequestId(_ctx.stringValue("DescribeImageSharePermissionResponse.RequestId"));<NEW_LINE>describeImageShare... | (_ctx.integerValue("DescribeImageSharePermissionResponse.PageSize")); |
1,060,238 | public void renderTooltip(PoseStack matrices, int mouseX, int mouseY) {<NEW_LINE>int checkX = mouseX - screen.leftPos;<NEW_LINE>int checkY = mouseY - screen.topPos;<NEW_LINE>if (isHovered(checkX, checkY)) {<NEW_LINE>FluidStack fluid = tank.getFluidInTank(TANK_INDEX);<NEW_LINE>int amount = fluid.getAmount();<NEW_LINE>in... | formatter.accept(capacity, tooltip); |
1,067,073 | private void checkForEachTableInSQL(Map<String, List<String>> notShardingTableMap, ArrayList<String> partNodeList, Pair<String, String> tn, RouteTableConfigInfo dataSourceTc, Set<TableStat.Relationship> relationships, Map<String, String> tableAliasMap) throws SQLException {<NEW_LINE>String sName = tn.getKey();<NEW_LINE... | , (ShardingTableConfig) tConfig, tSchema); |
1,120,557 | public void importGPX(final Uri uri, @Nullable final String mimeType, @Nullable final String pathName) {<NEW_LINE>final ContentResolver contentResolver = fromActivity.getContentResolver();<NEW_LINE>Log.i(<MASK><NEW_LINE>FileType fileType = new FileTypeDetector(uri, contentResolver).getFileType();<NEW_LINE>if (fileType ... | "importGPX: " + uri + ", mimetype=" + mimeType); |
1,708,214 | protected Message processRequest0(final CliRequestContext ctx, final ChangePeersRequest request, final RpcRequestClosure done) {<NEW_LINE>final List<PeerId> oldConf = ctx.node.listPeers();<NEW_LINE>final Configuration conf = new Configuration();<NEW_LINE>for (final String peerIdStr : request.getNewPeersList()) {<NEW_LI... | final PeerId peer = new PeerId(); |
1,504,636 | public ScheduledInstancesBlockDeviceMapping unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>ScheduledInstancesBlockDeviceMapping scheduledInstancesBlockDeviceMapping = new ScheduledInstancesBlockDeviceMapping();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = o... | ().unmarshall(context)); |
1,419,545 | public static <T> double similarity(T left, T right) {<NEW_LINE>int cross = 0;<NEW_LINE>if (left instanceof String) {<NEW_LINE>HashSet<Character> set = new HashSet<>();<NEW_LINE>String leftStr = (String) left;<NEW_LINE>String rightStr = (String) right;<NEW_LINE>for (int i = 0; i < leftStr.length(); i++) {<NEW_LINE>set.... | rightStr = (String[]) right; |
655,719 | public void processImage(int sourceID, long frameID, final BufferedImage buffered, ImageBase frame) {<NEW_LINE>if (trackerChanged) {<NEW_LINE>trackerChanged = false;<NEW_LINE>createNewTracker();<NEW_LINE>initializeTracker = true;<NEW_LINE>}<NEW_LINE>boolean grayScale = false;<NEW_LINE>if (tracker.getImageType().getFami... | long before = System.nanoTime(); |
1,454,269 | public void writeTo(StreamOutput out) throws IOException {<NEW_LINE><MASK><NEW_LINE>out.writeVInt(assignments.size());<NEW_LINE>for (Map.Entry<Reference, Symbol> e : assignments.entrySet()) {<NEW_LINE>Reference.toStream(e.getKey(), out);<NEW_LINE>Symbols.toStream(e.getValue(), out);<NEW_LINE>}<NEW_LINE>if (out.getVersi... | Symbols.toStream(uidSymbol, out); |
1,220,394 | public VariableMapping readOutputMapping(Statement statement) throws MatParseException {<NEW_LINE>VariableMapping mapping;<NEW_LINE>try {<NEW_LINE>mapping = parseMapping(statement, OM_HAS_NAME_SPACE);<NEW_LINE>} catch (final Exception e) {<NEW_LINE>throw new MatParseException("Unexpected mapping format", statement, e);... | ShaderNodeDefinition definition = shaderNode.getDefinition(); |
1,832,415 | public GetResourcePolicyResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GetResourcePolicyResult getResourcePolicyResult = new GetResourcePolicyResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<... | int originalDepth = context.getCurrentDepth(); |
697,700 | final ListModelQualityJobDefinitionsResult executeListModelQualityJobDefinitions(ListModelQualityJobDefinitionsRequest listModelQualityJobDefinitionsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listModelQualityJobDefinitionsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = execu... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "ListModelQualityJobDefinitions"); |
466,251 | public ODocument toStream() {<NEW_LINE>rwSpinLock.acquireReadLock();<NEW_LINE>try {<NEW_LINE>document.field("schemaVersion", CURRENT_VERSION_NUMBER);<NEW_LINE>Set<ODocument> cc = new HashSet<ODocument>();<NEW_LINE>for (OClass c : classes.values()) cc.add(((OClassImpl) c).toStream());<NEW_LINE>document.field("classes", ... | "globalProperties", globalProperties, OType.EMBEDDEDLIST); |
1,662,580 | public void engineError(boolean handshaked, ErrorReason reason) {<NEW_LINE>// Engine is dead. Let's forget about it.<NEW_LINE>engine = null;<NEW_LINE>// Remove any half-done messages from the pipes.<NEW_LINE>if (pipe != null) {<NEW_LINE>cleanPipes();<NEW_LINE>// Only send disconnect message if socket was accepted and h... | TIMEOUT || reason == ErrorReason.PROTOCOL); |
799,151 | void writeIdentityProvider(XMLExtendedStreamWriter writer, ModelNode model) throws XMLStreamException {<NEW_LINE>if (!model.isDefined()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>for (Property idp : model.asPropertyList()) {<NEW_LINE>writer.writeStartElement(Constants.XML.IDENTITY_PROVIDER);<NEW_LINE>writer.writeAttribute... | (Constants.Model.HTTP_CLIENT)); |
300,076 | private void writeVersionAccessorClass(ClassNode classNode) throws IOException {<NEW_LINE>boolean isProvider = classNode.isAlsoProvider();<NEW_LINE>String interfaces = isProvider ? " implements VersionNotationSupplier" : "";<NEW_LINE>String versionsClassName = classNode.getClassName();<NEW_LINE>Set<String> versionAlias... | versionsClassName + " extends VersionFactory " + interfaces + " {"); |
1,725,801 | private Object negate(Document arg) {<NEW_LINE>List<Object> list = new ArrayList<Object>();<NEW_LINE>for (Map.Entry<String, Object> entry : arg.entrySet()) {<NEW_LINE>if (entry.getKey().equals("$or")) {<NEW_LINE>list.add(asDocument("$nor", entry.getValue()));<NEW_LINE>} else if (entry.getKey().equals("$and")) {<NEW_LIN... | (asDocument("$or", list2)); |
469,836 | final DeleteJobResult executeDeleteJob(DeleteJobRequest deleteJobRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteJobRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_L... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "DeleteJob"); |
20,808 | public static Set<Path> copyJars(JReleaserContext context, JavaAssembler assembler, Path jarsDirectory, String platform) throws AssemblerProcessingException {<NEW_LINE>Set<Path> paths = new LinkedHashSet<>();<NEW_LINE>// resolve all first<NEW_LINE>if (isBlank(platform)) {<NEW_LINE>paths.add(assembler.getMainJar().getEf... | ).forEach(paths::add); |
102,694 | public static byte[] doHttpPost(String url, String data, boolean allowCache) throws IOException {<NEW_LINE>Response response = (allowCache ? getHttpClientWithCache() : getHttpClient()).newCall(new Request.Builder().url(url).post(JsonRequestBody.from(data)).header("Content-Type", "application/json").build()).execute();<... | 0] : responseBody.bytes(); |
560,267 | private static void selectSingle(Node node, String cipherString, List<SSLCipher> selected, Set<SSLCipher> deleted) {<NEW_LINE>if (cipherString.startsWith("!")) {<NEW_LINE>// Remove the ciphers from the list and prevent them from reappearing<NEW_LINE>List<SSLCipher> ciphers = getCiphersForCipherString(node, cipherString... | cipherString.substring(1))); |
1,454,080 | public static DescribeCdnUserDomainsByFuncResponse unmarshall(DescribeCdnUserDomainsByFuncResponse describeCdnUserDomainsByFuncResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeCdnUserDomainsByFuncResponse.setRequestId<MASK><NEW_LINE>describeCdnUserDomainsByFuncResponse.setPageNumber(_ctx.longValue("DescribeCdnUse... | (_ctx.stringValue("DescribeCdnUserDomainsByFuncResponse.RequestId")); |
496,025 | public static void shiftRightPackedDecimal(byte[] destination, int destinationOffset, int destinationPrecision, byte[] source, int sourceOffset, int sourcePrecision, int shiftAmount, boolean round, boolean checkOverflow) {<NEW_LINE>if ((destinationOffset + ((destinationPrecision / 2) + 1) > destination.length) || (dest... | sourcePrecision, shiftAmount, round, checkOverflow); |
1,526,586 | public ConcurrentHashMap<Integer, Map<Integer, Float>> loadTran(String fileName) throws IOException {<NEW_LINE>ConcurrentHashMap<Integer, Map<Integer, Float>> res = new ConcurrentHashMap<>();<NEW_LINE>DataInputStream in = new DataInputStream(new FileInputStream(fileName));<NEW_LINE>Map<Integer, Float> bufferSourceMap =... | word2prob.put(targetID, tranProb); |
1,811,230 | public JMXConnectorServer start() throws MalformedURLException, IOException, UnknownHostException {<NEW_LINE>final String name = "jmxrmi";<NEW_LINE>final String hostname = hostname();<NEW_LINE>final Map<String, Object> env = new HashMap<>();<NEW_LINE>env.put("jmx.remote.jndi.rebind", "true");<NEW_LINE>// Provide SSL-ba... | env.put("com.sun.jndi.rmi.factory.socket", sslCsf); |
1,360,264 | public ASTNode visitOutputClause(final OutputClauseContext ctx) {<NEW_LINE>OutputSegment result = new OutputSegment(ctx.start.getStartIndex(), ctx.stop.getStopIndex());<NEW_LINE>if (null != ctx.outputWithColumns()) {<NEW_LINE>OutputWithColumnsContext outputWithColumnsContext = ctx.outputWithColumns();<NEW_LINE>List<Out... | ColumnProjectionSegment outputColumn = new ColumnProjectionSegment(column); |
876,106 | private static CtStatement internalCompileStatement(CtElement st, CtTypeReference returnType) {<NEW_LINE>Factory f = st.getFactory();<NEW_LINE>String contents = createWrapperContent(st, f, returnType);<NEW_LINE>build(f, contents);<NEW_LINE>CtType<?> c = f.<MASK><NEW_LINE>// Get the part we want<NEW_LINE>CtMethod<?> wra... | Type().get(WRAPPER_CLASS_NAME); |
1,524,567 | public void onDisplayPreferenceDialog(Preference preference) {<NEW_LINE>// check if dialog is already showing.<NEW_LINE>if (getParentFragmentManager().findFragmentByTag(DIALOG_FRAGMENT_TAG) != null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>final DialogFragment f;<NEW_LINE>if (preference instanceof EditTextPreference) {<N... | newInstance(preference.getKey()); |
226,093 | public void marshall(Nodegroup nodegroup, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (nodegroup == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(nodegroup.getNodegroupName(), NODEGROUPNAME_BINDING);<NEW... | e.getMessage(), e); |
995,029 | public IspPlacement unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>IspPlacement ispPlacement = new IspPlacement();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurren... | int originalDepth = context.getCurrentDepth(); |
952,457 | public void onMatch(RelOptRuleCall call) {<NEW_LINE>LogicalProject project = (LogicalProject) call.rels[0];<NEW_LINE>XPlanTableScan tableScan = (XPlanTableScan) call.rels[1];<NEW_LINE>if (XPlanUtil.isSimpleProject(project)) {<NEW_LINE>if (tableScan.getProjects().isEmpty()) {<NEW_LINE>tableScan.getProjects().addAll(proj... | project.getInput(), null); |
1,486,142 | private void validateAndSet(URL baseUrl) {<NEW_LINE>try {<NEW_LINE>serverUrl = new URI(baseUrl.toString());<NEW_LINE>} catch (URISyntaxException e) {<NEW_LINE>throw new IllegalArgumentException("Invalid URI: " + baseUrl.toString(), e);<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>// Automatically set scheme based on auth server ... | IllegalArgumentException("Invalid URI: " + baseUrl, e); |
1,155,137 | public void onBindViewHolderAtZeroPosition(SubSettingViewHolder holder) {<NEW_LINE>// Audio track selection option includes "Auto" at the top.<NEW_LINE>holder.textView.setText(R.string.exo_track_selection_auto);<NEW_LINE>// hasSelectionOverride is true means there is an explicit track selection, not "Auto".<NEW_LINE>Tr... | (R.string.exo_track_selection_auto)); |
158,510 | public static DescribeVulDetailsResponse unmarshall(DescribeVulDetailsResponse describeVulDetailsResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeVulDetailsResponse.setRequestId(_ctx.stringValue("DescribeVulDetailsResponse.RequestId"));<NEW_LINE>List<Cve> cves = new ArrayList<Cve>();<NEW_LINE>for (int i = 0; i < ... | ("DescribeVulDetailsResponse.Cves[" + i + "].Classify")); |
549,741 | public static GetTaskDetailActivityResponse unmarshall(GetTaskDetailActivityResponse getTaskDetailActivityResponse, UnmarshallerContext _ctx) {<NEW_LINE>getTaskDetailActivityResponse.setRequestId(_ctx.stringValue("GetTaskDetailActivityResponse.RequestId"));<NEW_LINE>getTaskDetailActivityResponse.setHttpStatusCode(_ctx.... | (_ctx.booleanValue("GetTaskDetailActivityResponse.Successful")); |
1,043,131 | final GetSnapshotsResult executeGetSnapshots(GetSnapshotsRequest getSnapshotsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getSnapshotsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
388,615 | public Item removeItemWithIndex(int nodeIndex) {<NEW_LINE>if (isEmpty()) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>if (nodeIndex < 0 || nodeIndex >= size()) {<NEW_LINE>throw new IllegalArgumentException("Index must be between 0 and " + (size() - 1));<NEW_LINE>}<NEW_LINE>boolean startFromTheBeginning = nodeIndex <= si... | ? currentNode.next : currentNode.previous; |
278,749 | public void actionPerformed(ActionEvent e) {<NEW_LINE>X509Metadata metadata = new X509Metadata("whocares", "whocares");<NEW_LINE>File certificatesConfigFile = new File(folder, X509Utils.CA_CONFIG);<NEW_LINE>FileBasedConfig config = new FileBasedConfig(certificatesConfigFile, FS.detect());<NEW_LINE>NewCertificateConfig ... | showException(GitblitAuthority.this, x); |
930,290 | public XContentBuilder toXContent(XContentBuilder builder, Params params) throws IOException {<NEW_LINE>builder.startObject(Fields.SEGMENTS);<NEW_LINE>builder.field(Fields.COUNT, count);<NEW_LINE>builder.humanReadableField(Fields.MEMORY_IN_BYTES, Fields.MEMORY, getMemory());<NEW_LINE>builder.humanReadableField(Fields.T... | Fields.INDEX_WRITER_MEMORY, getIndexWriterMemory()); |
1,763,254 | final ListLocationsResult executeListLocations(ListLocationsRequest listLocationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listLocationsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
1,016,650 | public void arc(float x, float y, float radius, float start, float degrees, int segments) {<NEW_LINE>if (segments <= 0)<NEW_LINE>throw new IllegalArgumentException("segments must be > 0.");<NEW_LINE>float colorBits = color.toFloatBits();<NEW_LINE>float theta = (2 * MathUtils.PI * (degrees / 360.0f)) / segments;<NEW_LIN... | cx, y + cy, 0); |
1,454,247 | private RFuture<Long> trimAsync(StreamTrimArgs args, boolean trimStrict) {<NEW_LINE>StreamTrimArgsSource source = (StreamTrimArgsSource) args;<NEW_LINE>StreamTrimParams pps = source.getParams();<NEW_LINE>List<Object> params = new LinkedList<>();<NEW_LINE>params.add(getRawName());<NEW_LINE>if (pps.getMaxLen() > 0) {<NEW... | add(pps.getMinId()); |
1,445,856 | private Object JSONMerge(List<Object> parameters) throws ParserException {<NEW_LINE>Object json = asJSON(parameters.get(0).toString());<NEW_LINE>if (json instanceof JSONArray) {<NEW_LINE>// Create a new JSON Array to preserve immutability for the macro script.<NEW_LINE>JSONArray jarr = JSONArray.fromObject(json);<NEW_L... | jobj = JSONObject.fromObject(json); |
647,489 | private void loadNode899() {<NEW_LINE>PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.ServerType_ServerCapabilities_MaxBrowseContinuationPoints, new QualifiedName(0, "MaxBrowseContinuationPoints"), new LocalizedText("en", "MaxBrowseContinuationPoints"), LocalizedText.NULL_VALUE, UInteger.valueOf(... | .expanded(), true)); |
1,215,186 | ActionResult<Wo> execute(EffectivePerson effectivePerson) throws Exception {<NEW_LINE>String id = StringTools.uniqueToken();<NEW_LINE>Meta meta = new Meta();<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>meta.setId(id);<NEW_LINE>assignmentStringValue(meta);<NEW... | (assertProperties(o, meta)); |
487,793 | public long updateCurrentId(long origId, long newId, String ip, Integer port) {<NEW_LINE>long newIdFromAnotherNode = 0L;<NEW_LINE>try {<NEW_LINE>connection.setAutoCommit(false);<NEW_LINE>Map<Integer, ParameterContext> params = new HashMap<>(2);<NEW_LINE>MetaDbUtil.setParameter(1, <MASK><NEW_LINE>MetaDbUtil.setParameter... | params, ParameterMethod.setLong, newId); |
558,274 | private void adjustWithDayFraction(ThreadContext context, DateTime dt, final long[] rest) {<NEW_LINE>final RubyFixnum zero = RubyFixnum.zero(context.runtime);<NEW_LINE>int ival;<NEW_LINE>ival = RubyDateTime.getHour(context, zero, rest);<NEW_LINE>dt = dt.plusHours(ival);<NEW_LINE>if (rest[0] != 0) {<NEW_LINE>ival = Ruby... | .plusMillis((int) millis); |
1,209,409 | private static ITestNGMethod[] createMethods(ITestObjectFactory objectFactory, ITestNGMethod[] methods, IAnnotationFinder finder, boolean isBeforeSuite, boolean isAfterSuite, boolean isBeforeTest, boolean isAfterTest, boolean isBeforeClass, boolean isAfterClass, boolean isBeforeMethod, boolean isAfterMethod, XmlTest xm... | .getQualifiedName() + "()]. Static configuration methods can cause " + " unexpected behavior."; |
1,804,838 | private Task fetch(final File repository) {<NEW_LINE>final Task[] t = new Task[1];<NEW_LINE>GitProgressSupport supp = new GitProgressSupport.NoOutputLogging() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>protected void perform() {<NEW_LINE>RepositoryInfo info = RepositoryInfo.getInstance(repository);<NEW_LINE>try {<NEW_LINE... | getUris().get(0); |
719,843 | private void queue(Event event) {<NEW_LINE>if (s_reportInterval > 0) {<NEW_LINE>int eventType = eventType(event);<NEW_LINE>synchronized (s_reportLock) {<NEW_LINE>s_nHistory++;<NEW_LINE>s_nHistoryDist[eventType]++;<NEW_LINE>s_nQueuedDist[eventType]++;<NEW_LINE>}<NEW_LINE>int currentSize = m_events.size();<NEW_LINE>if (c... | = m_events.size() > m_maxQueueSize; |
1,347,061 | public AsyncFuture<Void> run(final ShellIO io, TaskParameters base) throws Exception {<NEW_LINE>final Parameters params = (Parameters) base;<NEW_LINE>final SuggestBackend s = <MASK><NEW_LINE>final ObjectMapper mapper = new ObjectMapper(new YAMLFactory());<NEW_LINE>final List<Callable<TestResult>> tests = new ArrayList<... | suggest.useOptionalGroup(params.group); |
450,977 | public List<TBrokerFileStatus> listPath(String path, boolean fileNameOnly, Map<String, String> properties) {<NEW_LINE>List<TBrokerFileStatus> resultFileStatus = null;<NEW_LINE>WildcardURI pathUri = new WildcardURI(path);<NEW_LINE>BrokerFileSystem fileSystem = getFileSystem(path, properties);<NEW_LINE>Path pathPattern =... | = new ArrayList<>(0); |
1,739,281 | public static void logCert(@NonNull X509Certificate x509Certificate, CharSequence charSequence) throws CertificateEncodingException {<NEW_LINE>int bitLength;<NEW_LINE>Principal subjectDN = x509Certificate.getSubjectDN();<NEW_LINE>Log.i(TAG, charSequence + " - Unique distinguished name: " + subjectDN);<NEW_LINE>logEncod... | PublicKey publicKey = x509Certificate.getPublicKey(); |
1,100,458 | /*<NEW_LINE>* (non-Javadoc)<NEW_LINE>*<NEW_LINE>* @see com.impetus.kundera.client.ClientBase#onPersist(com.impetus.kundera.<NEW_LINE>* metadata.model.EntityMetadata, java.lang.Object, java.lang.Object,<NEW_LINE>* java.util.List)<NEW_LINE>*/<NEW_LINE>@Override<NEW_LINE>protected void onPersist(EntityMetadata entityMetad... | entityMetadata.getTableName(), e); |
309,455 | private void onMarkerSelected(Marker marker) {<NEW_LINE>// Zoom to current location<NEW_LINE>GeoPoint coordinate = new GeoPoint(Double.parseDouble(mCurlat), Double.parseDouble(mCurlon));<NEW_LINE>mController.setZoom(14.0);<NEW_LINE>mController.animateTo(coordinate);<NEW_LINE>marker.showInfoWindow();<NEW_LINE>scrollView... | MapViewRealTimeActivity.this.startActivity(browserIntent); |
1,440,850 | public void testTemplate(TestExecutionContext testExecCtx, TestExecutionResources testExecResources, Object managedComponentObject) {<NEW_LINE>// Verify parameters<NEW_LINE>if (testExecCtx == null || testExecResources == null) {<NEW_LINE>Assert.fail("MetadataCompleteTestLogic.testTemplate(): Missing context and/or reso... | fail("Invalid Entity-A type specified ('" + entityAName + "'). Cannot execute the test."); |
248,657 | public static void response(ShardingService shardingService, String stmt) {<NEW_LINE>ShowTablesStmtInfo info;<NEW_LINE>try {<NEW_LINE>info = new ShowTablesStmtInfo(stmt);<NEW_LINE>} catch (Exception e) {<NEW_LINE>shardingService.writeErrMessage(ErrorCode.ER_PARSE_ERROR, e.toString());<NEW_LINE>return;<NEW_LINE>}<NEW_LI... | cSchema + "'", ErrorCode.ER_BAD_DB_ERROR); |
1,080,118 | public void solveVelocityConstraints(final SolverData data) {<NEW_LINE>Vec2 vA = <MASK><NEW_LINE>float wA = data.velocities[m_indexA].w;<NEW_LINE>Vec2 vB = data.velocities[m_indexB].v;<NEW_LINE>float wB = data.velocities[m_indexB].w;<NEW_LINE>final Vec2 vpA = pool.popVec2();<NEW_LINE>final Vec2 vpB = pool.popVec2();<NE... | data.velocities[m_indexA].v; |
1,775,971 | public void execute(long time) {<NEW_LINE>// Copy our input parameters for future threshold checks<NEW_LINE>prevInputs = new HashMap<String, Double>(modelInputs);<NEW_LINE>MultiTable <MASK><NEW_LINE>firstExecution = true;<NEW_LINE>// Set all of the results<NEW_LINE>for (IoMapper mapper : config.getOutputs()) {<NEW_LINE... | results = runSim(time, modelInputs); |
128,556 | public static ServerAddress createBlockingServer(HostAndPort address, TProcessor processor, TProtocolFactory protocolFactory, long maxMessageSize, String serverName, int numThreads, long threadTimeOut, final AccumuloConfiguration conf, long timeBetweenThreadChecks) throws TTransportException {<NEW_LINE>InetSocketAddres... | TServerSocket transport = new TServerSocket(isa); |
1,347,988 | private RubyNumeric powerFixnum(ThreadContext context, RubyFixnum other) {<NEW_LINE>Ruby runtime = context.runtime;<NEW_LINE>long a = value;<NEW_LINE>long b = other.value;<NEW_LINE>if (b < 0) {<NEW_LINE>RubyRational rational = RubyRational.newRationalRaw(runtime, this);<NEW_LINE>return (RubyNumeric) numFuncall(context,... | int_pow(context, a, b); |
1,128,414 | private void initPlayer(final boolean playOnReady) {<NEW_LINE>if (DEBUG) {<NEW_LINE>Log.d(<MASK><NEW_LINE>}<NEW_LINE>simpleExoPlayer = new ExoPlayer.Builder(context, renderFactory).setTrackSelector(trackSelector).setLoadControl(loadController).build();<NEW_LINE>simpleExoPlayer.addListener(this);<NEW_LINE>simpleExoPlaye... | TAG, "initPlayer() called with: playOnReady = [" + playOnReady + "]"); |
949,330 | public void visitToken(DetailAST ast) {<NEW_LINE>final int parentType = ast.getParent().getType();<NEW_LINE>final DetailAST modifiers = ast.getFirstChild();<NEW_LINE>if (parentType != TokenTypes.OBJBLOCK && (!ignoreFinal || modifiers.findFirstToken(TokenTypes.FINAL) == null)) {<NEW_LINE>final DetailAST variable = ast.f... | DetailAST semicolonAst = ast.getNextSibling(); |
972,423 | public final void initialize(String name, CaseInsensitiveStringMap options) {<NEW_LINE>this.cacheEnabled = PropertyUtil.propertyAsBoolean(options, CatalogProperties.CACHE_ENABLED, CatalogProperties.CACHE_ENABLED_DEFAULT);<NEW_LINE>long cacheExpirationIntervalMs = PropertyUtil.propertyAsLong(options, <MASK><NEW_LINE>// ... | CatalogProperties.CACHE_EXPIRATION_INTERVAL_MS, CatalogProperties.CACHE_EXPIRATION_INTERVAL_MS_DEFAULT); |
1,630,812 | public static ListVpcEndpointServiceResourcesResponse unmarshall(ListVpcEndpointServiceResourcesResponse listVpcEndpointServiceResourcesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listVpcEndpointServiceResourcesResponse.setRequestId(_ctx.stringValue("ListVpcEndpointServiceResourcesResponse.RequestId"));<NEW_LINE>lis... | ("ListVpcEndpointServiceResourcesResponse.Resources[" + i + "].RelatedDeprecatedEndpointCount")); |
1,745,905 | public synchronized void restartApp(Set<String> changedResources, ClassChangeInformation classChangeInformation) {<NEW_LINE>restarting = true;<NEW_LINE>if (consoleContext != null) {<NEW_LINE>consoleContext.reset();<NEW_LINE>}<NEW_LINE>stop();<NEW_LINE>Timing.restart(curatedApplication.getAugmentClassLoader());<NEW_LINE... | log.error("Failed to start quarkus", t); |
941,264 | protected Void doInBackground(Void... params) {<NEW_LINE>try {<NEW_LINE>GcmPubSub.getInstance(mContext).unsubscribe(gcmToken, topic);<NEW_LINE>mLogger.log(Log.INFO, "topic unsubscription succeeded." + "\ngcmToken: " + gcmToken + "\ntopic: " + topic);<NEW_LINE>// Save the token in the address book<NEW_LINE>Sender entry ... | topics.put(topic, false); |
688,845 | private String guessColumnName(ExecutableElement pkMethod) {<NEW_LINE>Element pkFieldvariable = guessField(pkMethod);<NEW_LINE>Element pkFieldElement = isFieldAccess ? pkFieldvariable : guessGetter(pkMethod);<NEW_LINE>if (pkFieldElement == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>// something is missed, may be... | substring(3).toUpperCase(); |
712,804 | final RecordHandlerProgressResult executeRecordHandlerProgress(RecordHandlerProgressRequest recordHandlerProgressRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(recordHandlerProgressRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
842,688 | private void processSummaryField(DocumentSummary summary, SummaryField field, boolean validate) {<NEW_LINE>var sourceField = schema.getField(field.getSingleSource());<NEW_LINE>if (sourceField != null) {<NEW_LINE>if (isSupportedComplexField(sourceField)) {<NEW_LINE>if (isComplexFieldWithOnlyStructFieldAttributes(sourceF... | field.setTransform(SummaryTransform.MATCHED_ATTRIBUTE_ELEMENTS_FILTER); |
1,337,357 | protected void readElementsFromXml(EwsServiceXmlReader reader) throws Exception {<NEW_LINE>reader.readStartElement(XmlNamespace.Messages, XmlElementNames.RootFolder);<NEW_LINE>int totalItemsInView = reader.readAttributeValue(Integer.class, XmlAttributeNames.TotalItemsInView);<NEW_LINE>boolean moreItemsAvailable = !read... | XmlNamespace.Messages, XmlElementNames.RootFolder); |
1,611,550 | public AirbyteConnectionStatus check(final JsonNode config) {<NEW_LINE>try {<NEW_LINE>final MqttDestinationConfig mqttConfig = MqttDestinationConfig.getMqttDestinationConfig(config);<NEW_LINE>final String testTopic = mqttConfig.getTestTopic();<NEW_LINE>if (!testTopic.isBlank()) {<NEW_LINE>try (final IMqttAsyncClient cl... | LOGGER.error("Exception attempting to connect to the MQTT broker: ", e); |
654,942 | public Optional<DotPortlet> xmlToPortlet(String xml) throws IOException, JDOMException {<NEW_LINE>InputStream stream = new ByteArrayInputStream(xml.getBytes("UTF-8"));<NEW_LINE>SAXBuilder builder = new SAXBuilder();<NEW_LINE>Document doc = (Document) builder.build(stream);<NEW_LINE>final Element node = doc.getRootEleme... | portletClass = node.getChildText("portlet-class"); |
53,790 | public List<DatabaseChangeViewModel> scanForChanges() {<NEW_LINE>if (database.getDatabasePath().isEmpty()) {<NEW_LINE>return Collections.emptyList();<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>List<DatabaseChangeViewModel> <MASK><NEW_LINE>// Parse the modified file<NEW_LINE>// Important: apply all post-load actions<NEW_LINE>Im... | changes = new ArrayList<>(); |
235,695 | public void closeCall(RuntimeException e, ServerCall<?, ?> call, Metadata headers, Consumer<GRpcExceptionScope.GRpcExceptionScopeBuilder> customizer) throws RuntimeException {<NEW_LINE>Status statusToSend = Status.INTERNAL;<NEW_LINE>Metadata metadataToSend = null;<NEW_LINE>final Optional<HandlerMethod> handlerMethod = ... | .orElseGet(Metadata::new)); |
990,478 | // @since 2.13<NEW_LINE>protected AnnotatedAndMetadata<AnnotatedMethod, JsonCreator.Mode> findFactoryMethodMetadata(AnnotatedMethod am) {<NEW_LINE>// First: return type must be compatible with the introspected class<NEW_LINE>// (i.e. allowed to be sub-class, although usually is the same class)<NEW_LINE>Class<?<MASK><NE... | > rt = am.getRawReturnType(); |
424,076 | private static serverObjects putBlogEntry(final serverObjects prop, final BlogBoard.BlogEntry entry, final String context, final int number, final boolean hasRights, final boolean xml) {<NEW_LINE>prop.putHTML("mode_entries_" + number + "_subject", UTF8.String(entry.getSubject()));<NEW_LINE>prop.putHTML("mode_entries_" ... | "mode_entries_" + number + "_commentsactive", "1"); |
450,674 | private void parseExtensions(EsniKeyRecord record) {<NEW_LINE>int extensionsLength = this.parseIntField(HandshakeByteLength.EXTENSION_LENGTH);<NEW_LINE>int i = 0;<NEW_LINE>while (i < extensionsLength) {<NEW_LINE>byte[] extensionType = this.parseByteArrayField(ExtensionByteLength.TYPE);<NEW_LINE>int contentLength = this... | extensionContentBytes = this.parseByteArrayField(contentLength); |
768,753 | protected void addJaxWs20Library() throws Exception {<NEW_LINE>SourceGroup[] sgs = SourceGroups.getJavaSourceGroups(project);<NEW_LINE>if (sgs.length > 0) {<NEW_LINE>FileObject srcRoot = sgs[0].getRootFolder();<NEW_LINE>ClassPath compileClassPath = ClassPath.getClassPath(srcRoot, ClassPath.COMPILE);<NEW_LINE>ClassPath ... | }, srcRoot, ClassPath.COMPILE); |
15,612 | public void invoke(final RestLiRequestData requestData, final RoutingResult invokableMethod, final RestLiArgumentBuilder restLiArgumentBuilder, final RestLiCallback callback) {<NEW_LINE>try {<NEW_LINE>ResourceMethodDescriptor resourceMethodDescriptor = invokableMethod.getResourceMethod();<NEW_LINE>ResourceMethodConfig ... | callback, resource, resourceContext, args); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.