idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,497,048 | public SignedCertificateTimestamp parse() {<NEW_LINE>try {<NEW_LINE>// Create SCT object & save encoded response in it<NEW_LINE>SignedCertificateTimestamp certificateTimestamp = new SignedCertificateTimestamp();<NEW_LINE>// Decode and parse SCT version<NEW_LINE>SignedCertificateTimestampVersion sctVersion = SignedCerti... | [] encodedExtension = parseByteArrayField(extensionLength); |
709,685 | private void checkAndInsertRoleParam(String sqlVariable, List<RelRoleViewDto> roles, User user, View view) {<NEW_LINE>List<SqlVariable> variables = JSONObject.parseArray(sqlVariable, SqlVariable.class);<NEW_LINE>if (CollectionUtils.isEmpty(roles)) {<NEW_LINE>relRoleViewMapper.deleteByViewId(view.getId());<NEW_LINE>retu... | collect(Collectors.toSet()); |
1,476,864 | public void onItemClick(AdapterView<?> adapterView, View view, int item, long l) {<NEW_LINE>Log.d("KP2AK", "clicked item: " + items.get(item).key);<NEW_LINE>if (items.get(item).value.startsWith("KP2ASPECIAL")) {<NEW_LINE>// change entry<NEW_LINE>Log.d("KP2AK", "clicked item: " + items.get(item).value);<NEW_LINE>String ... | theItem = items.get(item); |
1,847,730 | public void drawLabel(String text, GraphicInfo graphicInfo, boolean centered) {<NEW_LINE>float interline = 1.0f;<NEW_LINE>// text<NEW_LINE>if (text != null && text.length() > 0) {<NEW_LINE>Paint originalPaint = g.getPaint();<NEW_LINE>Font originalFont = g.getFont();<NEW_LINE>g.setPaint(LABEL_COLOR);<NEW_LINE>g.setFont(... | bb.getWidth() / 2); |
1,162,522 | private void preProcessAndRouteRequest(RestRequest restRequest, RestResponseChannel restResponseChannel, AsyncOperationTracker.Metrics preProcessingMetrics, ThrowingConsumer<RequestPath> routingAction) {<NEW_LINE>handlePrechecks(restRequest, restResponseChannel);<NEW_LINE>Callback<Void> errorCallback = (r, e) -> submit... | errorCallback.onCompletion(null, e); |
1,845,647 | public void init(final ServletConfig config) throws ServletException {<NEW_LINE>super.init(config);<NEW_LINE>this.shouldProxy = this.props.getBoolean("azkaban.should.proxy", false);<NEW_LINE>this.allowGroupProxy = this.props.getBoolean("allow.group.proxy", false);<NEW_LINE>logger.info("Hdfs browser should proxy: " + th... | viewers.add(this.defaultViewer); |
1,781,692 | public void apply(ModelPropertyContext context) {<NEW_LINE>Optional<Min> min = extractMin(context);<NEW_LINE>Optional<Max> max = extractMax(context);<NEW_LINE>// add support for @Min/@Max<NEW_LINE>Compatibility<AllowableRangeValues, NumericElementFacet> values = allowableRange(min, max);<NEW_LINE>LOGGER.debug(String.fo... | n.copyOf(facet))); |
1,632,088 | private void drawBorder(Canvas canvas, int borderWidth) {<NEW_LINE>if (borderWidth <= 0) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>final float halfBorderWidth = borderWidth * 1.0f / 2;<NEW_LINE>mBorderPaint.setColor(mIsSelected ? mSelectedBorderColor : mBorderColor);<NEW_LINE>mBorderPaint.setStrokeWidth(borderWidth);<NEW_... | .left = mRectF.left + halfBorderWidth; |
937,402 | public void commit(Xid xid, boolean onePhase) throws XAException {<NEW_LINE>if (successLimit == null || successLimit.getAndDecrement() > 0) {<NEW_LINE>System.out.println(this + ".commit");<NEW_LINE>xaRes.commit(xid, onePhase);<NEW_LINE>if (// XA connection kept open for recovery in the case of activation spec<NEW_LINE>... | out.println(this + ".commit - intentional failure"); |
1,513,750 | private static void toSlime(Application application, Cluster cluster, NodeList applicationNodes, MetricsDb metricsDb, NodeRepository nodeRepository, Cursor clustersObject) {<NEW_LINE>NodeList nodes = applicationNodes.not().retired().<MASK><NEW_LINE>if (nodes.isEmpty())<NEW_LINE>return;<NEW_LINE>ClusterResources current... | cluster(cluster.id()); |
1,089,592 | final ListFHIRImportJobsResult executeListFHIRImportJobs(ListFHIRImportJobsRequest listFHIRImportJobsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listFHIRImportJobsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
169,384 | final DeleteDocumentResult executeDeleteDocument(DeleteDocumentRequest deleteDocumentRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteDocumentRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_LINE>Request<DeleteDocumentRequest> request = nu... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
106,496 | public static void main(String[] args) {<NEW_LINE>String dir = UtilIO.pathExample("calibration/stereo/Bumblebee2_Chess/");<NEW_LINE>StereoParameters param = CalibrationIO.load(<MASK><NEW_LINE>// load images<NEW_LINE>BufferedImage origLeft = UtilImageIO.loadImage(dir, "left05.jpg");<NEW_LINE>BufferedImage origRight = Ut... | new File(dir, "stereo.yaml")); |
1,497,048 | public SignedCertificateTimestamp parse() {<NEW_LINE>try {<NEW_LINE>// Create SCT object & save encoded response in it<NEW_LINE>SignedCertificateTimestamp certificateTimestamp = new SignedCertificateTimestamp();<NEW_LINE>// Decode and parse SCT version<NEW_LINE>SignedCertificateTimestampVersion sctVersion = SignedCerti... | extensionLength = parseIntField(CertificateTransparencyLength.EXTENSION_LENGTH); |
888,969 | HttpServer create(final TlsCertificateDefinition serverCert, final TlsCertificateDefinition acceptedClientCerts, final Path workDir, final boolean tlsEnabled) {<NEW_LINE>try {<NEW_LINE>final Path serverFingerprintFile = workDir.resolve("server_known_clients");<NEW_LINE>populateFingerprintFile(serverFingerprintFile, acc... | router = Router.router(vertx); |
243,250 | protected void doInBeforeTrace(SpanEventRecorder recorder, Object target, Object[] args) {<NEW_LINE>DatabaseInfo databaseInfo = (target instanceof DatabaseInfoAccessor) ? ((DatabaseInfoAccessor) <MASK><NEW_LINE>if (databaseInfo == null) {<NEW_LINE>databaseInfo = UnKnownDatabaseInfo.INSTANCE;<NEW_LINE>}<NEW_LINE>recorde... | target)._$PINPOINT$_getDatabaseInfo() : null; |
1,560,392 | public void handleApplicationCommandRequest(SerialMessage serialMessage, int offset, int endpoint) {<NEW_LINE>logger.trace("Handle Message Sensor Binary Request");<NEW_LINE>logger.debug("NODE {}: Received Sensor Binary Request (v{})", this.getNode().getNodeId(), this.getVersion());<NEW_LINE>int command = serialMessage.... | ().getKey())); |
980,567 | private void checkSQLServerTables() throws SQLException {<NEW_LINE>LOGGER.entering(CLASSNAME, "checkSQLServerTables");<NEW_LINE>setCreateSQLServerStringsMap();<NEW_LINE>createTableIfNotExists(tableNames.get(CHECKPOINT_TABLE_KEY)<MASK><NEW_LINE>createTableIfNotExists(tableNames.get(JOB_INSTANCE_TABLE_KEY), SQLServerCrea... | , SQLServerCreateStrings.get(SQLSERVER_CREATE_TABLE_CHECKPOINTDATA)); |
1,593,793 | private DecryptionResult decryptCredentials(@NonNull final String alias, @NonNull final CipherStorage current, @NonNull final ResultSet resultSet, @Rules @NonNull final String rules, @NonNull final PromptInfo promptInfo) throws CryptoFailedException, KeyStoreAccessException {<NEW_LINE>final String storageName = resultS... | alias, current, oldStorage, decryptionResult); |
723,196 | public void execute(FlinkCommandArgs flinkCommandArgs) {<NEW_LINE><MASK><NEW_LINE>String configFile = flinkCommandArgs.getConfigFile();<NEW_LINE>Config config = new ConfigBuilder<>(configFile, engine).getConfig();<NEW_LINE>ExecutionContext<FlinkEnvironment> executionContext = new ExecutionContext<>(config, engine);<NEW... | EngineType engine = flinkCommandArgs.getEngineType(); |
258,539 | public static MutableRoaringBitmap priorityqueue_or(ImmutableRoaringBitmap... bitmaps) {<NEW_LINE>if (bitmaps.length == 0) {<NEW_LINE>return new MutableRoaringBitmap();<NEW_LINE>} else if (bitmaps.length == 1) {<NEW_LINE>return bitmaps[0].toMutableRoaringBitmap();<NEW_LINE>}<NEW_LINE>// we buffer the call to getLongSiz... | Integer x2 = pq.poll(); |
1,795,202 | public static void replacePathClassLoader(Context base, ClassLoader original, NClassLoader target) throws Exception {<NEW_LINE>NClassLoader loader = target;<NEW_LINE>Field pathListField = findField(original, "pathList");<NEW_LINE>pathListField.setAccessible(true);<NEW_LINE>Object originPathListObject = pathListField.ge... | (dexFile.getName())); |
1,197,908 | private void drawText(Canvas canvas, int color, String text, int x, int y, int stroke, int padding) {<NEW_LINE>Paint paint = new Paint();<NEW_LINE>Paint.<MASK><NEW_LINE>paint.setStyle(Paint.Style.FILL);<NEW_LINE>paint.setColor(color);<NEW_LINE>paint.setAntiAlias(true);<NEW_LINE>x += stroke / 2;<NEW_LINE>y += stroke / 2... | FontMetrics metrics = paint.getFontMetrics(); |
1,027,660 | public boolean updatePowerState(final long instanceId, final long powerHostId, final VirtualMachine.PowerState powerState, Date wisdomEra) {<NEW_LINE>return Transaction.execute(new TransactionCallback<Boolean>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public Boolean doInTransaction(TransactionStatus status) {<NEW_LINE>... | instance.getPowerStateUpdateCount() + 1); |
738,548 | public String buildItemProductDisplayName() {<NEW_LINE>final I_M_HU_PI_Item_Product itemProduct = getM_HU_PI_Item_Product();<NEW_LINE>final I_M_HU_PI_Item piItem = itemProduct.getM_HU_PI_Item();<NEW_LINE>if (piItem == null || piItem.getM_HU_PI_Item_ID() <= 0) {<NEW_LINE>return "";<NEW_LINE>}<NEW_LINE>final StringBuilde... | (" x ").append(qtyStr); |
1,827,082 | public static RemoteMemoryTable newRemoteMemoryTable(int proxy, Table table) {<NEW_LINE>int recordCount = table.length();<NEW_LINE>int[] seqs = table.dataStruct().getPKIndex();<NEW_LINE>int keyCount = seqs == null ? 0 : seqs.length;<NEW_LINE>Object keyValue = null;<NEW_LINE>if (keyCount == 1) {<NEW_LINE>if (recordCount... | ] vals = new Object[keyCount]; |
1,431,272 | public void writeFirstSpanEvent(Buffer buffer, SpanEventBo spanEventBo, SpanEncodingContext<?> encodingContext) {<NEW_LINE>final SpanEventBitField bitField = SpanEventBitField.buildFirst(spanEventBo);<NEW_LINE>final byte firstSpanBitField1 = (byte) bitField.getBitField();<NEW_LINE>buffer.putByte(firstSpanBitField1);<NE... | writeAnnotationList(buffer, annotationBoList, encodingContext); |
1,826,213 | public void checkModVersionRequirements(Value reqs) {<NEW_LINE>if (reqs == null)<NEW_LINE>return;<NEW_LINE>if (!(reqs instanceof MapValue)) {<NEW_LINE>throw new InternalExpressionException("`requires` field must be a map of mod dependencies or a function to be executed");<NEW_LINE>}<NEW_LINE>Map<Value, Value> requireme... | "' in 'requires': " + e.getMessage()); |
1,683,277 | public SaModel createModelFor(DataSource ds) {<NEW_LINE>if (ds instanceof Application) {<NEW_LINE>Application app = (Application) ds;<NEW_LINE>if (Host.LOCALHOST.equals(app.getHost())) {<NEW_LINE>JvmJvmstatModel jvmstat = JvmJvmstatModelFactory.getJvmstatModelFor(app);<NEW_LINE>File jdkHome = new File(jvmstat.getJavaHo... | File(coredump.getExecutable()); |
266,225 | public static double[] filter(double[] b, double[] a, double[] x, boolean bNormalize, double[] zi) {<NEW_LINE>int n;<NEW_LINE>double x_terms;<NEW_LINE>double y_terms;<NEW_LINE>int ind;<NEW_LINE>double[] y = new double[x.length];<NEW_LINE>int nb = b.length - 1;<NEW_LINE><MASK><NEW_LINE>if (bNormalize) {<NEW_LINE>// Norm... | int na = a.length - 1; |
1,618,696 | private static Field findSingleFieldUsingStrategy(FieldMatcherStrategy strategy, Object object, boolean checkHierarchy, Class<?> startClass) {<NEW_LINE>assertObjectInGetInternalStateIsNotNull(object);<NEW_LINE>Field foundField = null;<NEW_LINE>final Class<?> originalStartClass = startClass;<NEW_LINE>while (startClass !... | TooManyFieldsFoundException("Two or more fields matching " + strategy + "."); |
714,134 | public static synchronized void prepareRuntimeEnv(MLContext mlContext) {<NEW_LINE>prepareStartupScript(mlContext);<NEW_LINE>String workDir = mlContext.getWorkDir().getAbsolutePath();<NEW_LINE>// create virtual env<NEW_LINE>try {<NEW_LINE>PythonUtil.setupVirtualEnv(mlContext);<NEW_LINE>} catch (IOException e) {<NEW_LINE... | getOrDefault(MLConstants.REMOTE_CODE_ZIP_FILE, ""); |
1,609,454 | public void testAsyncBulkheadSmall() throws Exception {<NEW_LINE>syntheticTaskManager.runTest(() -> {<NEW_LINE>// First two tasks should start<NEW_LINE>SyntheticTask<Void> task1 = syntheticTaskManager.newTask();<NEW_LINE>SyntheticTask<Void> task2 = syntheticTaskManager.newTask();<NEW_LINE>Future<Void> future1 = bean1.r... | > task4 = syntheticTaskManager.newTask(); |
611,279 | public SystemActionWorkflowActionMapping deserialize(final JsonParser parser, final DeserializationContext context) throws IOException, JsonProcessingException {<NEW_LINE>final ObjectNode objectNode = parser.readValueAsTree();<NEW_LINE>final JsonNode nodeWorkflowAction = objectNode.get("workflowAction");<NEW_LINE>final... | get("ownerContentType").asBoolean(); |
1,061,297 | public void createMenuItems(Bundle savedInstanceState) {<NEW_LINE>Context ctx = getContext();<NEW_LINE>if (ctx == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>ApplicationMode mode = getAppMode();<NEW_LINE>boolean customProfile = mode.isCustomProfile();<NEW_LINE>String title = getString(customProfile ? R.string.restore_... | getColoredSelectableDrawable(ctx, colorNoAlpha, 0.3f); |
1,614,106 | private void commitLoop() {<NEW_LINE>Map<ComputationState, Windmill.ComputationCommitWorkRequest.Builder> computationRequestMap = new HashMap<>();<NEW_LINE>while (running.get()) {<NEW_LINE>computationRequestMap.clear();<NEW_LINE>Windmill.CommitWorkRequest.Builder commitRequestBuilder = Windmill.CommitWorkRequest.newBui... | ).setState(State.COMMITTING); |
226,714 | public void Picture(@Asset final String path) {<NEW_LINE>if (MediaUtil.isExternalFile(container.$context(), path) && container.$form().isDeniedPermission(Manifest.permission.READ_EXTERNAL_STORAGE)) {<NEW_LINE>container.$form().askPermission(Manifest.permission.READ_EXTERNAL_STORAGE, new PermissionResultHandler() {<NEW_... | ViewUtil.setImage(view, drawable); |
320,925 | public static QueryMapVersionsResponse unmarshall(QueryMapVersionsResponse queryMapVersionsResponse, UnmarshallerContext _ctx) {<NEW_LINE>queryMapVersionsResponse.setRequestId(_ctx.stringValue("QueryMapVersionsResponse.RequestId"));<NEW_LINE>queryMapVersionsResponse.setMessage(_ctx.stringValue("QueryMapVersionsResponse... | (_ctx.stringValue("QueryMapVersionsResponse.DynamicCode")); |
973,618 | private void genCheckAutoType(String classNameType, MethodWriter mw, int JSON_READER, int FIELD_TYPE, int FIELD_NAME, int FEATURES, int AUTO_TYPE_OBJECT_READER) {<NEW_LINE>Label checkArrayAutoTypeNull_ = new Label();<NEW_LINE>mw.visitVarInsn(Opcodes.ALOAD, THIS);<NEW_LINE>mw.visitVarInsn(Opcodes.ALOAD, JSON_READER);<NE... | visitJumpInsn(Opcodes.IFNULL, checkArrayAutoTypeNull_); |
1,626,840 | // header structure for analyzer<NEW_LINE>public DataType toDataType() throws DuplicateNameException, IOException {<NEW_LINE>Structure structure = new StructureDataType("yaffs2Hdr", 0);<NEW_LINE>structure.add(DWORD, "objectType", null);<NEW_LINE>structure.<MASK><NEW_LINE>structure.add(WORD, "checksum", null);<NEW_LINE>... | add(DWORD, "parentObjectId", null); |
1,401,850 | public static <T1, T2> double weightedConditionalEntropy(ArrayList<T1> vector, ArrayList<T2> condition, ArrayList<Double> weights) {<NEW_LINE>if ((vector.size() == condition.size()) && (vector.size() == weights.size())) {<NEW_LINE>double vectorLength = vector.size();<NEW_LINE>double condEntropy = 0.0;<NEW_LINE>Weighted... | = e.getValue().weight; |
1,778,538 | private boolean initializeDatasourceXml(String dbaddress, String dbport, String dbuser, String dbpassword, String dbcatalog) throws Exception {<NEW_LINE>boolean result = false;<NEW_LINE>try {<NEW_LINE>String connectionUrl = String.format(jdbcUrlTemplate, dbaddress, dbport, dbcatalog);<NEW_LINE>Document document = Docum... | ).replace(WEB_XML, DATASOURCE_XML); |
1,223,821 | private static Variable unbox(Variable var) {<NEW_LINE>if (returnType instanceof ValueType.Primitive) {<NEW_LINE>switch(((ValueType.Primitive) returnType).getKind()) {<NEW_LINE>case BOOLEAN:<NEW_LINE>var = unbox(var, Boolean.class, boolean.class);<NEW_LINE>break;<NEW_LINE>case BYTE:<NEW_LINE>var = unbox(var, <MASK><NEW... | Byte.class, byte.class); |
1,703,057 | public void decode(FacesContext context, DataTable table) {<NEW_LINE>// FilterMeta#column must be updated since local value<NEW_LINE>// (from column) must be decoded by FilterFeature#decodeFilterValue<NEW_LINE>Map<String, FilterMeta> filterBy = table.getFilterByAsMap();<NEW_LINE>table.updateFilterByValuesWithFilterRequ... | params.get(clientId + "_rppDD"); |
1,467,662 | private void cloneMetaData(CharSequence tableName, CharSequence backupRoot, int mkDirMode, TableReader reader) {<NEW_LINE>srcPath.of(backupRoot).concat(tableName).slash$();<NEW_LINE>if (ff.exists(srcPath)) {<NEW_LINE>throw CairoException.instance(0).put("Backup dir for table \"").put(tableName).put("\" already exists [... | $(), MemoryTag.MMAP_DEFAULT); |
1,723,136 | public Request<PutRolePermissionsBoundaryRequest> marshall(PutRolePermissionsBoundaryRequest putRolePermissionsBoundaryRequest) {<NEW_LINE>if (putRolePermissionsBoundaryRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<PutRolePermissionsBou... | request.addParameter("Action", "PutRolePermissionsBoundary"); |
985,801 | private static boolean handleDurabilityLoss(@NotNull Set<BlockState> treeFellerBlocks, @NotNull ItemStack inHand, @NotNull Player player) {<NEW_LINE>// Treat the NBT tag for unbreakable and the durability enchant differently<NEW_LINE><MASK><NEW_LINE>if (meta != null && meta.isUnbreakable()) {<NEW_LINE>return true;<NEW_... | ItemMeta meta = inHand.getItemMeta(); |
531,878 | public Object calculate(Context ctx) {<NEW_LINE>if (left == null) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new RQException("\"++\"" + mm.getMessage("operator.missingLeftOperation"));<NEW_LINE>}<NEW_LINE>if (right == null) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new R... | MessageManager mm = EngineMessage.get(); |
752,194 | private static void initializeClasses() {<NEW_LINE>try {<NEW_LINE>Class.forName(CoroutineExitException.class.getName());<NEW_LINE>Class.forName(WispThreadWrapper.class.getName());<NEW_LINE>Class.forName(TaskDispatcher.class.getName());<NEW_LINE>Class.forName(StartShutdown.class.getName());<NEW_LINE>Class.forName(Corout... | MAX_VALUE, TimeOut.Action.JDK_UNPARK); |
262,552 | public static TreeMap<Integer, Integer> calculateFanOuts(final FST fst) {<NEW_LINE>final int[] result = new int[256];<NEW_LINE>fst.visitInPreOrder(state -> {<NEW_LINE>int count = 0;<NEW_LINE>for (int arc = fst.getFirstArc(state); arc != 0; arc = fst.getNextArc(arc)) {<NEW_LINE>count++;<NEW_LINE>}<NEW_LINE>result[count]... | int high = result.length - 1; |
231,336 | public FieldLevelEncryptionProfileSummary unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>FieldLevelEncryptionProfileSummary fieldLevelEncryptionProfileSummary = new FieldLevelEncryptionProfileSummary();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalD... | ().unmarshall(context)); |
1,796,519 | public void releasePersistenceSpaceIdentifier(PersistenceSpaceIdentifier<?> identifier) throws CachePersistenceException {<NEW_LINE>String name = null;<NEW_LINE>for (Map.Entry<String, PersistenceSpace> entry : knownPersistenceSpaces.entrySet()) {<NEW_LINE>if (entry.getValue().identifier.equals(identifier)) {<NEW_LINE>n... | persistenceSpace = knownPersistenceSpaces.remove(name); |
1,596,411 | public static String toXML(PortletPreferencesImpl prefs) throws SystemException {<NEW_LINE>try {<NEW_LINE>Map preferences = prefs.getPreferences();<NEW_LINE>DocumentFactory docFactory = DocumentFactory.getInstance();<NEW_LINE>Element portletPreferences = docFactory.createElement("portlet-preferences");<NEW_LINE>Iterato... | .entrySet().iterator(); |
7,588 | public DescribeExportTasksResult describeExportTasks(DescribeExportTasksRequest describeExportTasksRequest) throws AmazonServiceException, AmazonClientException {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeExportTasksRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionCont... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,401,027 | public Answer execute(final UpgradeSnapshotCommand command, final CitrixResourceBase citrixResourceBase) {<NEW_LINE>final String secondaryStorageUrl = command.getSecondaryStorageUrl();<NEW_LINE>final String backedUpSnapshotUuid = command.getSnapshotUuid();<NEW_LINE>final Long volumeId = command.getVolumeId();<NEW_LINE>... | Connection conn = citrixResourceBase.getConnection(); |
997,766 | private static ArrowType parseComplexFormat(String format, String payload) throws NumberFormatException, UnsupportedOperationException, IllegalStateException {<NEW_LINE>switch(format) {<NEW_LINE>case "d":<NEW_LINE>{<NEW_LINE>int[] parts = payloadToIntArray(payload);<NEW_LINE>Preconditions.checkState(parts.length == 2 |... | ("Format %s:%s is not supported", format, payload)); |
545,825 | protected BillingEvent createNewReenableEvent(final DateTime odEventTime, final BillingEvent previousEvent) throws CatalogApiException {<NEW_LINE>// All fields are populated with the event state from before the blocking period, for invoice to resume invoicing<NEW_LINE>final int billCycleDay = previousEvent.getBillCycle... | > usages = previousEvent.getUsages(); |
1,836,853 | public void start() throws Throwable {<NEW_LINE>if (!started.compareAndSet(false, true)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>boss = new NioEventLoopGroup(1, new DefaultThreadFactory("qos-boss", true));<NEW_LINE>worker = new NioEventLoopGroup(0, new DefaultThreadFactory("qos-worker", true));<NEW_LINE>ServerBootstrap ... | host, port).sync(); |
703,420 | public static void shareNodeFromChat(Context context, MegaNode node, long chatId, long msgId) {<NEW_LINE>if (!MegaNodeUtil.shouldContinueWithoutError(context, "sharing node", node)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>String path = getLocalFile(node);<NEW_LINE>if (!isTextEmpty(path)) {<NEW_LINE>logDebug("Node is dow... | context, new File(path)); |
1,813,479 | private ClusteringAlgorithm parseAlgorithm(ClusterRequest template, ClusterRequest clusteringRequest) throws TerminateRequestException {<NEW_LINE>String algorithmName = firstNotNull(clusteringRequest.algorithm, template.algorithm);<NEW_LINE>if (algorithmName == null) {<NEW_LINE>throw new TerminateRequestException(Error... | algorithm, clusteringRequest.parameters, classFromName); |
1,581,101 | protected void onPostExecute(Bundle result) {<NEW_LINE>if (checkTokenError(result))<NEW_LINE>return;<NEW_LINE>ArrayList<SocialPerson> socialPersons = result.getParcelableArrayList(RESULT_USERS_ARRAY);<NEW_LINE>if (result.containsKey(FRIENDS)) {<NEW_LINE>if (!handleRequestResult(result, REQUEST_GET_FRIENDS))<NEW_LINE>re... | onGetFriendsComplete(getID(), socialPersons); |
1,237,087 | public void subscribeActual(Observer<? super R> observer) {<NEW_LINE>ObservableSource<? extends R> other;<NEW_LINE>try {<NEW_LINE>other = Objects.requireNonNull(mapper.apply(value), "The mapper returned a null ObservableSource");<NEW_LINE>} catch (Throwable e) {<NEW_LINE>Exceptions.throwIfFatal(e);<NEW_LINE>EmptyDispos... | >) other).get(); |
616,327 | public boolean apply(Game game, Ability source) {<NEW_LINE>Player player = game.getPlayer(source.getControllerId());<NEW_LINE>if (player == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>TargetCard target = new TargetCardInGraveyard(0, 1);<NEW_LINE>target.setNotTarget(true);<NEW_LINE>player.choose(outcome, target, ... | Zone.EXILED, source, game); |
1,186,252 | boolean match(char patternTypeSuffix, char[] patternPkg, int matchRulePkg, char[] patternTypeName, int matchRuleType, int typeKind, char[] pkg, char[] typeName) {<NEW_LINE>switch(patternTypeSuffix) {<NEW_LINE>case IIndexConstants.CLASS_SUFFIX:<NEW_LINE>if (typeKind != TypeDeclaration.CLASS_DECL)<NEW_LINE>return false;<... | patternTypeName = CharOperation.toLowerCase(patternTypeName); |
1,346,053 | public void testLTCRollbackAndStartGlobalTran() throws Exception {<NEW_LINE>Future<Integer> future = scheduledExecutor.schedule(new Callable<Integer>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public Integer call() throws Exception {<NEW_LINE>Connection con = dataSource.getConnection();<NEW_LINE>try {<NEW_LINE>con.setAu... | createStatement().executeQuery("VALUES (13)"); |
1,221,712 | public List<Object> doInPreparedStatement(PreparedStatement ps) throws SQLException {<NEW_LINE>ColumnMapRowMapper columnMapRowMapper = new ColumnMapRowMapper(getMappingRegistry().getTypeRegistry());<NEW_LINE>ReturnSqlParameter result = SqlParameterUtils.withReturnResult("TMP", new RowMapperResultSetExtractor<>(columnMa... | (), resultSet, null)); |
501,493 | public List<Placement> resolve(DayView dayView, double contentWidth) {<NEW_LINE>if (entryViews == null || entryViews.isEmpty()) {<NEW_LINE>return Collections.emptyList();<NEW_LINE>}<NEW_LINE>columns = new ArrayList<>();<NEW_LINE>columns.add(new VisualBoundsColumn());<NEW_LINE>for (EntryViewBase<?> entryView : entryView... | placements = new ArrayList<>(); |
1,795,801 | final TagResourceResult executeTagResource(TagResourceRequest tagResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(tagResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
1,158,624 | public int maxPoints(int[][] points) {<NEW_LINE>int n = points.length;<NEW_LINE>if (n < 3) {<NEW_LINE>return n;<NEW_LINE>}<NEW_LINE>int res = 0;<NEW_LINE>for (int i = 0; i < n - 1; ++i) {<NEW_LINE>Map<String, Integer> <MASK><NEW_LINE>int max = 0;<NEW_LINE>int duplicate = 0;<NEW_LINE>for (int j = i + 1; j < n; ++j) {<NE... | kCounter = new HashMap<>(); |
1,275,586 | public void deleteEventHubConsumerGroupById(String id) {<NEW_LINE>String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");<NEW_LINE>if (resourceGroupName == null) {<NEW_LINE>throw logger.logExceptionAsError(new IllegalArgumentException(String.format("The resource ID '%s' is not valid. Missing path s... | eventHubEndpointName, name, Context.NONE); |
1,050,029 | private static boolean doTestSetup(String testSetupSource, boolean silent) {<NEW_LINE>Region r = Region.create(0, 0, 100, 100);<NEW_LINE>Image img = new Image(r.getScreen().capture(r).getImage());<NEW_LINE>Pattern p = new Pattern(img);<NEW_LINE><MASK><NEW_LINE>boolean success = (null != f.find(p));<NEW_LINE>log(lvl, "t... | Finder f = new Finder(img); |
1,656,648 | public void actionPerformed(ActionEvent e) {<NEW_LINE>Jvm jvm = JvmFactory.getJVMFor(selectedApp);<NEW_LINE>if (jvm != null) {<NEW_LINE>ApplicationType eat = ApplicationTypeManager.getDefault().<MASK><NEW_LINE>final ApplicationTypeForm form = new ApplicationTypeForm(eat);<NEW_LINE>final DialogDescriptor[] dd = new Dial... | newType(jvm.getMainClass()); |
1,247,829 | private static void formatUnusedResourcesTask(JsonObject jsonObject) {<NEW_LINE>JsonArray resources = jsonObject.getAsJsonArray("unused-resources");<NEW_LINE>Map<String, List<String>> group = new HashMap<String, List<String>>();<NEW_LINE>jsonObject.addProperty("total-count", resources.size());<NEW_LINE>for (JsonElement... | .indexOf('.', 2)); |
607,856 | private static Object checkReferencedSelection(Node node) {<NEW_LINE>if (node instanceof Resolvable<?>) {<NEW_LINE>Object resolved = null;<NEW_LINE>try {<NEW_LINE>if (node instanceof ReferenceType) {<NEW_LINE>ResolvedType dec = ((ReferenceType) node).resolve();<NEW_LINE>String name = toInternal(dec);<NEW_LINE>return ne... | toInternal(type.getType()); |
486,051 | public int askTrustSSLServer(String certMessage, boolean allowPermanently) {<NEW_LINE>if ((SvnClientExceptionHandler.EX_NO_CERTIFICATE & handledExceptions) != SvnClientExceptionHandler.EX_NO_CERTIFICATE) {<NEW_LINE>// XXX test me<NEW_LINE>return -1;<NEW_LINE>}<NEW_LINE>AcceptCertificatePanel acceptCertificatePanel = ne... | (SvnClientExceptionHandler.class, "CTL_Error_CertFailed")); |
199,307 | public static void main(String[] args) throws IOException, ClassNotFoundException {<NEW_LINE>// Write V1<NEW_LINE>var fishV1 = new RainbowFish("Zed", 10, 11, 12);<NEW_LINE>LOGGER.info("fishV1 name={} age={} length={} weight={}", fishV1.getName(), fishV1.getAge(), fishV1.getLengthMeters(<MASK><NEW_LINE>RainbowFishSerial... | ), fishV1.getWeightTons()); |
518,765 | public Download addDownload(Torrent torrent, File torrent_file, File data_location, int initial_state) throws DownloadException {<NEW_LINE>if (torrent_file == null) {<NEW_LINE>String torrent_dir = null;<NEW_LINE>if (COConfigurationManager.getBooleanParameter("Save Torrent Files")) {<NEW_LINE>try {<NEW_LINE>torrent_dir ... | data_dir = COConfigurationManager.getStringParameter("Default save path"); |
546,093 | public static JsChunkSpec create(String specString, boolean isFirstChunk) {<NEW_LINE>// Format is "<name>:<num-js-files>[:[<dep>,...][:]]".<NEW_LINE>String[] parts = specString.split(":");<NEW_LINE>if (parts.length < 2 || parts.length > 4) {<NEW_LINE>throw new FlagUsageException("Expected 2-4 colon-delimited parts in "... | [1] + "' for module: " + name); |
675,275 | public void publish0(final RfQResponsePublisherRequest request, final RfQReportType rfqReportType) {<NEW_LINE>final I_C_RfQResponse rfqResponse = request.getC_RfQResponse();<NEW_LINE>//<NEW_LINE>// Check and get the user's mail where we will send the email to<NEW_LINE>final I_AD_User userTo = rfqResponse.getAD_User();<... | EMailSentStatus emailSentStatus = email.send(); |
1,776,369 | public void marshall(BatchWriteOperationResponse batchWriteOperationResponse, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (batchWriteOperationResponse == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(bat... | batchWriteOperationResponse.getDetachPolicy(), DETACHPOLICY_BINDING); |
1,131,539 | public DataType toDataType() throws DuplicateNameException, IOException {<NEW_LINE>Structure struct = new StructureDataType(FBPT.class.getSimpleName(), 0);<NEW_LINE>struct.add(STRING, FBPK_Constants.FBPT.length(), "magic", null);<NEW_LINE>struct.add(DWORD, "unknown1", null);<NEW_LINE>struct.add(DWORD, "unknown2", null)... | add(DWORD, "unknownH", null); |
1,784,878 | NodeView newNodeView(final NodeModel model, final MapView map, final Container parent, final int index) {<NEW_LINE>final NodeView newView = new <MASK><NEW_LINE>parent.add(newView, index);<NEW_LINE>newView.setMainView(newMainView(newView));<NEW_LINE>if (map.isDisplayable())<NEW_LINE>updateNewView(newView);<NEW_LINE>else... | NodeView(model, map, parent); |
1,335,762 | public StateMachine registryStateMachine(StateMachine stateMachine) {<NEW_LINE>String stateMachineName = stateMachine.getName();<NEW_LINE>String tenantId = stateMachine.getTenantId();<NEW_LINE>if (stateLangStore != null) {<NEW_LINE>StateMachine oldStateMachine = stateLangStore.getLastVersionStateMachine(stateMachineNam... | setId(oldStateMachine.getId()); |
776,116 | private void writeAttributes(final ITreeWriter writer, final NodeModel node, final NodeStyleModel style, final boolean forceFormatting) {<NEW_LINE>final Color color = forceFormatting ? nsc.getColor(node, StyleOption.FOR_UNSELECTED_NODE) : style.getColor();<NEW_LINE>if (color != null) {<NEW_LINE>ColorUtils.addColorAttri... | FOR_UNSELECTED_NODE) : style.getShapeConfiguration(); |
353,874 | public BeanDefinition parse(Element element, ParserContext pc) {<NEW_LINE>CompositeComponentDefinition compositeDef = new CompositeComponentDefinition(element.getTagName(), pc.extractSource(element));<NEW_LINE>pc.pushContainingComponent(compositeDef);<NEW_LINE>boolean prePostAnnotationsEnabled = !element.hasAttribute(A... | MethodSecurityExpressionHandlerBean.class).getBeanDefinition(); |
1,577,859 | static int utf8DecodeValid(AbstractTruffleString a, Object arrayA, int i) {<NEW_LINE>int b = readS0(a, arrayA, i);<NEW_LINE>if (b < 0x80) {<NEW_LINE>return b;<NEW_LINE>}<NEW_LINE>int nBytes = utf8CodePointLength(b);<NEW_LINE>int codepoint = b <MASK><NEW_LINE>assert 1 < nBytes && nBytes < 5 : nBytes;<NEW_LINE>assert i +... | & (0xff >>> nBytes); |
979,982 | public AgentConfig updateAgentConfig(AgentConfig agentConfig) throws Exception {<NEW_LINE>List<GaugeConfig> existingConfigs = Lists.newArrayList(agentConfig.getGaugeConfigList());<NEW_LINE>ListIterator<GaugeConfig> i = existingConfigs.listIterator();<NEW_LINE>boolean found = false;<NEW_LINE>while (i.hasNext()) {<NEW_LI... | loopVersion = Versions.getVersion(loopConfig); |
812,033 | private Thread startThread(ThreadContext context, Runnable runnable) throws RaiseException, OutOfMemoryError {<NEW_LINE>final Ruby runtime = context.runtime;<NEW_LINE>try {<NEW_LINE>Thread thread = new Thread(runnable);<NEW_LINE>thread.setDaemon(true);<NEW_LINE>this.file = context.getFile();<NEW_LINE>this.line = contex... | ).interruptMaskStack, this.interruptMaskStack); |
89,294 | public void updateCompassValue(float val) {<NEW_LINE>Float prevHeading = heading;<NEW_LINE>heading = val;<NEW_LINE>boolean headingChanged = prevHeading == null;<NEW_LINE>if (!headingChanged) {<NEW_LINE>headingChanged = Math.abs(MapUtils.degreesDiff<MASK><NEW_LINE>}<NEW_LINE>if (mapView != null) {<NEW_LINE>float speedFo... | (prevHeading, heading)) > COMPASS_HEADING_THRESHOLD; |
58,081 | public static SAML11AuthorizationDecisionStatementType parseSAML11AuthorizationDecisionStatement(XMLEventReader xmlEventReader) throws ParsingException {<NEW_LINE>SAML11AuthorizationDecisionStatementType authzDecision = null;<NEW_LINE>StartElement startElement = StaxParserUtil.getNextStartElement(xmlEventReader);<NEW_L... | , SAML11DecisionType.valueOf(decisionValue)); |
720,874 | void removeKeyAndRightChildAt(PageCursor cursor, int keyPos, int keyCount, long stableGeneration, long unstableGeneration, CursorContext cursorContext) throws IOException {<NEW_LINE>placeCursorAtActualKey(cursor, keyPos, INTERNAL);<NEW_LINE>int keyOffset = cursor.getOffset();<NEW_LINE>long keyValueSize = readKeyValueSi... | bytesKeyOffset() + childSize()); |
1,742,945 | public void contrastiveDivergence(RestrictedBoltzmannMachine rbm, double[] input, double lr, int k) {<NEW_LINE>// The positive gradient mean & samples (P) - Only for hidden (H)<NEW_LINE>double[] meanPH = new double[rbm.getHiddenCount()];<NEW_LINE>double[] samplePH = new double[rbm.getHiddenCount()];<NEW_LINE>// The neg... | double[rbm.getVisibleCount()]; |
1,671,288 | public Request<ModifyTargetGroupAttributesRequest> marshall(ModifyTargetGroupAttributesRequest modifyTargetGroupAttributesRequest) {<NEW_LINE>if (modifyTargetGroupAttributesRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<ModifyTargetGroup... | <ModifyTargetGroupAttributesRequest>(modifyTargetGroupAttributesRequest, "AmazonElasticLoadBalancing"); |
186,049 | public byte[] toByteArray() {<NEW_LINE>// computes the real size of the bytecode of this class<NEW_LINE><MASK><NEW_LINE>int nbFields = 0;<NEW_LINE>FieldWriter fb = firstField;<NEW_LINE>while (fb != null) {<NEW_LINE>++nbFields;<NEW_LINE>size += fb.getSize();<NEW_LINE>fb = fb.next;<NEW_LINE>}<NEW_LINE>int nbMethods = 0;<... | int size = 24 + 2 * interfaceCount; |
531,495 | public Object instantiateItem(ViewGroup container, int position) {<NEW_LINE>String[] mTitles = new String[] { context.getString(R.string.allow_acces_media_title), context.getString(R.string.allow_acces_camera_title), context.getString(R.string.allow_acces_calls_title) };<NEW_LINE>String[] mSubtitles = new String[] { co... | .setText(mTitles[position]); |
60,187 | public final Condition compare(Comparator comparator, T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6, T7 t7, T8 t8, T9 t9, T10 t10, T11 t11) {<NEW_LINE>return compare(comparator, row(Tools.field(t1, (DataType) dataType(0)), Tools.field(t2, (DataType) dataType(1)), Tools.field(t3, (DataType) dataType(2)), Tools.field(t4, (Dat... | ) dataType(10)))); |
1,180,506 | public void marshall(APNSVoipChannelResponse aPNSVoipChannelResponse, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (aPNSVoipChannelResponse == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(aPNSVoipChannel... | aPNSVoipChannelResponse.getEnabled(), ENABLED_BINDING); |
1,508,427 | public Void visitTypeCast(TypeCastTree node, Void p) {<NEW_LINE>AnnotatedTypeMirror exprType = atypeFactory.getAnnotatedType(node.getExpression());<NEW_LINE>AnnotatedTypeMirror castType = atypeFactory.getAnnotatedType(node);<NEW_LINE>AnnotationMirror exprAnno = null, castAnno = null;<NEW_LINE>// find commitment annotat... | ).isSubtype(exprAnno, castAnno); |
871,974 | private void drawArea(DrawInfo ctx) {<NEW_LINE>ctx.areaOffset = ctx.startOffset;<NEW_LINE>ctx.areaLength = ctx.endOffset - ctx.startOffset;<NEW_LINE>// Ask all the contexts first to possibly find out<NEW_LINE>// the first fragment length<NEW_LINE>ctx.layerUpdateOffset = Integer.MAX_VALUE;<NEW_LINE>int layersLength = ct... | naco = l.getNextActivityChangeOffset(ctx); |
1,266,220 | public void storeSettings(Object settings) {<NEW_LINE>WizardDescriptor wdNew = (WizardDescriptor) settings;<NEW_LINE>wdNew.putProperty(WIZ_NEW_FILE_TITLE, null);<NEW_LINE>if (this.bindingInfoPnl.getSchemaName() != null) {<NEW_LINE>wdNew.putProperty(JAXBWizModuleConstants.SCHEMA_NAME, this.bindingInfoPnl.getSchemaName()... | this.bindingInfoPnl.getPackageName()); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.