idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,719,643 | protected void renderMergedOutputModel(Map<String, Object> model, HttpServletRequest request, HttpServletResponse response) {<NEW_LINE>response.setContentType("application/jrd+json");<NEW_LINE>HttpStatus code = (HttpStatus) model.get(HttpCodeView.CODE);<NEW_LINE>if (code == null) {<NEW_LINE>// default to 200<NEW_LINE>c... | String) model.get("issuer"); |
904,404 | public void startProxy() throws IOException {<NEW_LINE>try {<NEW_LINE>initKeyStore();<NEW_LINE>} catch (GeneralSecurityException e) {<NEW_LINE>log.error("Could not initialise key store", e);<NEW_LINE><MASK><NEW_LINE>} catch (IOException e) {<NEW_LINE>// make sure we log the error<NEW_LINE>log.error("Could not initialis... | throw new IOException("Could not create keystore", e); |
1,815,364 | public StaticObject ToReflectedField(@JavaType(Class.class) StaticObject unused, @Handle(Field.class) long fieldId, @SuppressWarnings("unused") boolean isStatic) {<NEW_LINE>Field field = fieldIds.getObject(fieldId);<NEW_LINE>assert field.getDeclaringKlass().<MASK><NEW_LINE>StaticObject fields = getVM().JVM_GetClassDecl... | isAssignableFrom(unused.getMirrorKlass()); |
784,290 | private RowRecord constructRowRecordFromValueArray() throws StatementExecutionException {<NEW_LINE>List<Field> <MASK><NEW_LINE>for (int i = 0; i < ioTDBRpcDataSet.columnSize; i++) {<NEW_LINE>Field field;<NEW_LINE>int index = i + 1;<NEW_LINE>int datasetColumnIndex = i + START_INDEX;<NEW_LINE>if (ioTDBRpcDataSet.ignoreTi... | outFields = new ArrayList<>(); |
1,150,827 | final RetryBuildBatchResult executeRetryBuildBatch(RetryBuildBatchRequest retryBuildBatchRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(retryBuildBatchRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(F... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
1,120,903 | public boolean onJsAlert(WebView view, String url, String message, JsResult jsResult) {<NEW_LINE>if (message != null && message.startsWith("selendroid<")) {<NEW_LINE>jsResult.confirm();<NEW_LINE>synchronized (syncObject) {<NEW_LINE>String res = message.replaceFirst("selendroid<", "");<NEW_LINE>int i = res.indexOf(">:")... | res.replace("\u00a5", "\\"); |
270,717 | private Attributes storeTo(ConfigurationChanges.ModifiedObject ldapObj, TransferCapability tc, Attributes attrs) {<NEW_LINE>BasicAttribute objectclass = new BasicAttribute("objectclass", "dicomTransferCapability");<NEW_LINE>attrs.put(objectclass);<NEW_LINE>LdapUtils.storeNotNullOrDef(ldapObj, attrs, "cn", tc.getCommonN... | (tc.getPreferredTransferSyntaxes())); |
1,095,365 | public void repaint(int x, int y, int w, int h) {<NEW_LINE>Rectangle rect;<NEW_LINE>synchronized (dirtyRegionLock) {<NEW_LINE>if (dirtyRegion == null) {<NEW_LINE>if (repaintPending) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>rect = new Rectangle(x, y, w, h);<NEW_LINE>setDirtyRegion(rect);<NEW_LINE>} else if (dirtyRegion.ge... | size.setWidth(x2 - x1); |
1,089,169 | public static ByteSizeValue parseBytesSizeValue(String sValue) throws EsHadoopIllegalArgumentException {<NEW_LINE>long bytes;<NEW_LINE>sValue = org.elasticsearch.hadoop.util.StringUtils.deleteWhitespace(sValue);<NEW_LINE>try {<NEW_LINE>if (sValue.endsWith("k") || sValue.endsWith("K")) {<NEW_LINE>bytes = (long) (Double.... | .length() - 1)); |
1,402,021 | private static void deeplyAppendParameter(StringBuilder sbuf, Object o, Set<Object[]> seen) {<NEW_LINE>if (o == null) {<NEW_LINE>sbuf.append("null");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (o.getClass().isArray() == false) {<NEW_LINE>safeObjectAppend(sbuf, o);<NEW_LINE>} else {<NEW_LINE>// check for primitive array ty... | , (int[]) o); |
1,763,535 | public boolean removeRelationPointIfOnLineBetweenNeighbourPoints() {<NEW_LINE>boolean updateNecessary = false;<NEW_LINE>if (points.size() > 2) {<NEW_LINE>ListIterator<RelationPoint<MASK><NEW_LINE>PointDoubleIndexed leftNeighbour = iter.next().getPoint();<NEW_LINE>PointDoubleIndexed pointToCheck = iter.next().getPoint()... | > iter = points.listIterator(); |
846,923 | final ListEntitledApplicationsResult executeListEntitledApplications(ListEntitledApplicationsRequest listEntitledApplicationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listEntitledApplicationsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetri... | (super.beforeMarshalling(listEntitledApplicationsRequest)); |
1,671,458 | public void execute() throws BuildException {<NEW_LINE>StringBuilder out = new StringBuilder();<NEW_LINE>if (fileSets.size() == 0) {<NEW_LINE>throw new BuildException("No filesets supplied.");<NEW_LINE>}<NEW_LINE>if ((property == null) && (null == file)) {<NEW_LINE>throw new BuildException("property or output file not ... | thisFileSet.getDirectoryScanner(getProject()); |
26,806 | ArrayList<Object> new99() /* reduce AIfStatement */<NEW_LINE>{<NEW_LINE>@SuppressWarnings("hiding")<NEW_LINE>ArrayList<Object> nodeList <MASK><NEW_LINE>@SuppressWarnings("unused")<NEW_LINE>ArrayList<Object> nodeArrayList3 = pop();<NEW_LINE>@SuppressWarnings("unused")<NEW_LINE>ArrayList<Object> nodeArrayList2 = pop();<N... | = new ArrayList<Object>(); |
1,242,771 | private void sendInitialEntities(NetData.NetMessage.Builder message) {<NEW_LINE>int[] initial = netInitial.toArray();<NEW_LINE>netInitial.clear();<NEW_LINE>Arrays.sort(initial);<NEW_LINE>for (int netId : initial) {<NEW_LINE>netRelevant.add(netId);<NEW_LINE>EntityRef entity = networkSystem.getEntity(netId);<NEW_LINE>if ... | newBuilder().setEntity(entityData); |
874,279 | public static GetDeviceInternetPortResponse unmarshall(GetDeviceInternetPortResponse getDeviceInternetPortResponse, UnmarshallerContext _ctx) {<NEW_LINE>getDeviceInternetPortResponse.setRequestId(_ctx.stringValue("GetDeviceInternetPortResponse.RequestId"));<NEW_LINE>getDeviceInternetPortResponse.setInstanceId(_ctx.stri... | ("GetDeviceInternetPortResponse.NetworkInfo[" + i + "].ISP")); |
199,899 | private BLangRecordVariable createBLangRecordVariable(MappingBindingPatternNode mappingBindingPatternNode) {<NEW_LINE>BLangRecordVariable recordVariable = (BLangRecordVariable) TreeBuilder.createRecordVariableNode();<NEW_LINE>List<BLangRecordVariableKeyValue> fieldBindingPatternsList = new ArrayList<>();<NEW_LINE>for (... | variableName().name()); |
251,936 | public void stopStartedContainers(boolean keepContainer, boolean removeVolumes, boolean removeCustomNetworks, GavLabel gavLabel) throws DockerAccessException, ExecException {<NEW_LINE>List<DockerAccessException> thrownExceptions = new ArrayList<>();<NEW_LINE>Set<Network> networksToRemove = new HashSet<>();<NEW_LINE>for... | StringJoiner(",", "(", ")"); |
1,193,507 | public static QueryScriptWaveformsResponse unmarshall(QueryScriptWaveformsResponse queryScriptWaveformsResponse, UnmarshallerContext _ctx) {<NEW_LINE>queryScriptWaveformsResponse.setRequestId(_ctx.stringValue("QueryScriptWaveformsResponse.RequestId"));<NEW_LINE>queryScriptWaveformsResponse.setCode(_ctx.stringValue("Que... | (_ctx.integerValue("QueryScriptWaveformsResponse.HttpStatusCode")); |
771,687 | public Object calculate(Context ctx) {<NEW_LINE>Machines mcHS = new Machines();<NEW_LINE>String path = null;<NEW_LINE>if (param == null) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new RQException("sync" + mm.getMessage("function.missingParam"));<NEW_LINE>} else if (param.isLeaf()) {<NEW_LINE>Obj... | + mm.getMessage("function.paramTypeError")); |
1,808,075 | private static BPartnerQuery createBPartnerQuery(@NonNull final IdentifierString bpartnerIdentifier, final OrgId orgId) {<NEW_LINE>final Type type = bpartnerIdentifier.getType();<NEW_LINE>final BPartnerQuery.BPartnerQueryBuilder builder = BPartnerQuery.builder();<NEW_LINE>if (orgId != null) {<NEW_LINE>builder.onlyOrgId... | asValue()).build(); |
1,326,609 | private void displayDeleteSavedLogsDialog() {<NEW_LINE>List<Path> logFiles = SaveLogHelper.getLogFiles();<NEW_LINE>if (logFiles.isEmpty()) {<NEW_LINE>Toast.makeText(this, R.string.no_saved_logs, <MASK><NEW_LINE>return;<NEW_LINE>}<NEW_LINE>CharSequence[] filenameArray = SaveLogHelper.getFormattedFilenames(this, logFiles... | Toast.LENGTH_SHORT).show(); |
241,770 | public static DescribeGatewayActionsResponse unmarshall(DescribeGatewayActionsResponse describeGatewayActionsResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeGatewayActionsResponse.setRequestId(_ctx.stringValue("DescribeGatewayActionsResponse.RequestId"));<NEW_LINE>describeGatewayActionsResponse.setMessage(_ctx.s... | = new ArrayList<Action>(); |
357,755 | public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {<NEW_LINE>// WUtil.debug(new String("In do Post"),"");<NEW_LINE>HttpSession sess = request.getSession();<NEW_LINE>MobileSessionCtx wsc = MobileSessionCtx.get(request);<NEW_LINE>Properties ctx = wsc.ctx;<NE... | ArrayList) sess.getAttribute(NODES_ID); |
479,688 | private void initializeDestinations() {<NEW_LINE>List<ASTNode> result = new ArrayList<>();<NEW_LINE>BodyDeclaration decl = fAnalyzer.getEnclosingBodyDeclaration();<NEW_LINE>ASTNode current = ASTResolving.findParentType(decl.getParent());<NEW_LINE>if (fAnalyzer.isValidDestination(current)) {<NEW_LINE>result.add(current)... | binding = ASTNodes.getEnclosingType(current); |
201,491 | protected void buildConfigurationDialog() {<NEW_LINE>configurationDialog = new JDialog(UISupport.getMainFrame());<NEW_LINE>configurationDialog.setTitle(assertion.getConfigurationDialogTitle());<NEW_LINE>configurationDialog.addWindowListener(new WindowAdapter() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void windowO... | setToolTipText(assertion.getContentAreaToolTipText()); |
461,835 | public void lockToPortraitUpsideDown() {<NEW_LINE>final Activity activity = getCurrentActivity();<NEW_LINE>if (activity == null)<NEW_LINE>return;<NEW_LINE>activity.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_REVERSE_PORTRAIT);<NEW_LINE>isLocked = true;<NEW_LINE>// force send an UI orientation event<NEW_LINE... | lockParams.putString("orientation", lastOrientationValue); |
1,042,778 | public Optional<PsiMethod> createBuilderMethodIfNecessary(@NotNull PsiClass containingClass, @Nullable PsiMethod psiMethod, @NotNull PsiClass builderPsiClass, @NotNull PsiAnnotation psiAnnotation) {<NEW_LINE>final String builderMethodName = getBuilderMethodName(psiAnnotation);<NEW_LINE>if (!builderMethodName.isEmpty() ... | methodBuilder.withModifier(PsiModifier.STATIC); |
563,599 | // ----------- preconditions --------------<NEW_LINE>@Override<NEW_LINE>protected RefactoringStatus doCheckFinalConditions(IProgressMonitor pm, CheckConditionsContext checkContext) throws CoreException {<NEW_LINE>try {<NEW_LINE>// $NON-NLS-1$<NEW_LINE>pm.beginTask("", 3);<NEW_LINE>RefactoringStatus result = new Refacto... | 1)), method, name); |
744,961 | protected void performAction(final Node[] nodes) {<NEW_LINE>RequestProcessor.getDefault().post(new Runnable() {<NEW_LINE><NEW_LINE>public void run() {<NEW_LINE>try {<NEW_LINE>// Resolve DataObject<NEW_LINE>DataObject dobj = (DataObject) nodes[0].getLookup().lookup(DataObject.class);<NEW_LINE>if (dobj == null)<NEW_LINE>... | createFrom(dobj.getPrimaryFile()); |
1,126,108 | public void onReceive(Context context, Intent intent) {<NEW_LINE>if (getReactApplicationContext().hasActiveCatalystInstance()) {<NEW_LINE>RemoteMessage message = intent.getParcelableExtra("data");<NEW_LINE>WritableMap params = Arguments.createMap();<NEW_LINE>WritableMap fcmData = Arguments.createMap();<NEW_LINE>if (mes... | "action", notification.getClickAction()); |
13,522 | private void addJoinRelation(ItemFuncEqual filter) {<NEW_LINE>JoinColumnInfo jiLeft = initJoinColumnInfo(filter.arguments().get(0));<NEW_LINE>JoinColumnInfo jiRight = initJoinColumnInfo(filter.arguments().get(1));<NEW_LINE>JoinRelation relation = new JoinRelation(jiLeft, jiRight, filter);<NEW_LINE>for (JoinRelationGrou... | > onColumns = group.getSelList(); |
521,807 | private static void testValueOf() {<NEW_LINE>// TODO(b/36863439): Uncomment the following line once Enum.valueOf is implemented.<NEW_LINE>// assertTrue(Enum.valueOf(Planet.class, "SATURN")<NEW_LINE>assertTrue(Planet.valueOf("MERCURY") == Planet.MERCURY);<NEW_LINE>assertTrue(Planet.valueOf("VENUS") == Planet.VENUS);<NEW... | ("JUPITER") == Planet.JUPITER); |
1,533,204 | public void marshall(StorageDescriptor storageDescriptor, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (storageDescriptor == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(storageDescriptor.getColumns(), C... | storageDescriptor.getInputFormat(), INPUTFORMAT_BINDING); |
93,335 | public ItemStack execute(BlockSource source, ItemStack stack) {<NEW_LINE>Direction direction = source.getBlockState().getValue(DispenserBlock.FACING);<NEW_LINE><MASK><NEW_LINE>double d0 = source.x() + (double) direction.getStepX() * 1.125D;<NEW_LINE>double d1 = Math.floor(source.y()) + (double) direction.getStepY();<NE... | Level world = source.getLevel(); |
1,649,246 | public void resolveIncident(OpenIncident openIncident, long resolveTime) throws Exception {<NEW_LINE>int adjustedTTL = Common.getAdjustedTTL(Ints.saturatedCast(HOURS.toSeconds(Constants.RESOLVED_INCIDENT_EXPIRATION_HOURS)), resolveTime, clock);<NEW_LINE>BoundStatement boundStatement = insertResolvedIncidentPS.bind();<N... | .setBytes(i++, conditionBytes); |
1,853,315 | public Sql[] generateSql(AddPrimaryKeyStatement statement, Database database, SqlGeneratorChain sqlGeneratorChain) {<NEW_LINE>StringBuilder sql = new StringBuilder();<NEW_LINE>sql.append("ALTER TABLE ");<NEW_LINE>sql.append(database.escapeTableName(statement.getCatalogName(), statement.getSchemaName(), statement.getTab... | ), getAffectedPrimaryKey(statement)) }; |
1,026,884 | public void testServletSubmitsManagedTaskThatInvokesTxMandatory(HttpServletRequest request, HttpServletResponse response) throws Exception {<NEW_LINE>PrintWriter out = response.getWriter();<NEW_LINE>Future<?> future = executor.submit(new Callable<Object>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public Object call() th... | Object ejbTxKey = bean.runAsMandatory(); |
1,344,991 | public com.amazonaws.services.ecr.model.EmptyUploadException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.ecr.model.EmptyUploadException emptyUploadException = new com.amazonaws.services.ecr.model.EmptyUploadException(null);<NEW_LINE>int originalDepth = conte... | String currentParentElement = context.getCurrentParentElement(); |
575,282 | private static boolean randomSubsetRunner(TimedExecutor executor, int n, int k) throws Exception {<NEW_LINE>List<List<Integer>> results = new ArrayList<>();<NEW_LINE>executor.run(() -> {<NEW_LINE>for (int i = 0; i < 1000000; ++i) {<NEW_LINE>results.add(randomSubset(n, k));<NEW_LINE>}<NEW_LINE>});<NEW_LINE>int totalPoss... | RandomSequenceChecker.binomialCoefficient(n, k); |
1,844,714 | private void refreshController(boolean keepLocation) throws IOException {<NEW_LINE>int diffIndex = -1;<NEW_LINE>if (controller != null) {<NEW_LINE>diffIndex = controller.getDifferenceIndex();<NEW_LINE>controller.removePropertyChangeListener(this);<NEW_LINE>addPropertyChangeListener(this);<NEW_LINE>if (locationKeeper !=... | DiffController.createEnhanced(ss1, ss2); |
1,552,383 | public PushPhysicalPlan buildPushPhysicalPlan(final LogicalPlanNode logicalPlanNode, final Context context, final Optional<PushOffsetRange> offsetRange, final Optional<String> catchupConsumerGroup) {<NEW_LINE><MASK><NEW_LINE>PushDataSourceOperator dataSourceOperator = null;<NEW_LINE>final OutputNode outputNode = logica... | final String catchupConsumerGroupId = getConsumerGroupId(catchupConsumerGroup); |
231,591 | void userRestoredMode(ModeImpl slidingMode, ModeImpl modeToRestore) {<NEW_LINE>TopComponent tcToSelect = modeToRestore.getPreviousSelectedTopComponent();<NEW_LINE>setModeMinimized(modeToRestore, false);<NEW_LINE>WindowManagerImpl wm = WindowManagerImpl.getInstance();<NEW_LINE>for (TopComponent tc : slidingMode.getOpene... | id = wm.findTopComponentID(tc); |
1,676,591 | public void updateFromOverride(MethodTree methodTree, ExecutableElement methodElt, AnnotatedExecutableType overriddenMethod) {<NEW_LINE>// Don't infer types for code that isn't presented as source.<NEW_LINE>if (!ElementUtils.isElementFromSourceCode(methodElt)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>String file = storag... | PARAMETER, argATM, paramATM, file); |
413,457 | public Snapshot archiveSnapshot(Long snapshotId) {<NEW_LINE>SnapshotInfo snapshotOnPrimary = snapshotFactory.getSnapshot(snapshotId, DataStoreRole.Primary);<NEW_LINE>if (snapshotOnPrimary == null || !snapshotOnPrimary.getStatus().equals(ObjectInDataStoreStateMachine.State.Ready)) {<NEW_LINE>throw new CloudRuntimeExcept... | snapshotOnSecondary = snapshotSrv.backupSnapshot(snapshotOnPrimary); |
693,302 | private void visitMethod(Node member, ClassDeclarationMetadata metadata) {<NEW_LINE>Node qualifiedMemberAccess = getQualifiedMemberAccess(member, metadata);<NEW_LINE>Node method = member<MASK><NEW_LINE>// Use the source info from the method (a FUNCTION) not the MEMBER_FUNCTION_DEF<NEW_LINE>// because the MEMBER_FUNCTIO... | .getLastChild().detach(); |
331,907 | private ImmutableMap<String, Object> convertSelects(Cell cell, UnconfiguredBuildTarget target, RuleDescriptor<?> descriptor, Map<String, Object> attrs, CellRelativePath pathRelativeToProjectRoot, DependencyStack dependencyStack) {<NEW_LINE>ImmutableMap.Builder<String, Object> result = ImmutableMap.builder();<NEW_LINE>D... | get(attr.getKey()); |
1,744,666 | private static boolean isEar(int i, float[] xv, float[] yv) {<NEW_LINE>float dx0, dy0, dx1, dy1;<NEW_LINE>dx0 = dy0 = dx1 = dy1 = 0;<NEW_LINE>if (i >= xv.length || i < 0 || xv.length < 3)<NEW_LINE>return false;<NEW_LINE>int upper = i + 1;<NEW_LINE>int lower = i - 1;<NEW_LINE>if (i == 0) {<NEW_LINE>dx0 = xv[0] - xv[xv.l... | [0] - yv[i]; |
14,123 | private void untar(InputStream is, Path dir, boolean gzip) throws IOException {<NEW_LINE>InputStream bis;<NEW_LINE>if (gzip) {<NEW_LINE>bis = new GzipCompressorInputStream(new BufferedInputStream(is));<NEW_LINE>} else {<NEW_LINE>bis = new BufferedInputStream(is);<NEW_LINE>}<NEW_LINE>bis = new CloseShieldFilterInputStre... | resolve(entryName).toAbsolutePath(); |
1,018,565 | public void show(double xScaleLow, double xScaleHigh, double yScaleLow, double yScaleHigh, double radiusOfCircleAroundVertex) {<NEW_LINE><MASK><NEW_LINE>StdDraw.setXscale(xScaleLow, xScaleHigh);<NEW_LINE>StdDraw.setYscale(yScaleLow, yScaleHigh);<NEW_LINE>StdDraw.setPenRadius(0.002D);<NEW_LINE>StdDraw.setPenColor(Color.... | StdDraw.setCanvasSize(500, 400); |
1,010,176 | public UnconditionalFlowInfo unconditionalFieldLessCopy() {<NEW_LINE>// TODO (maxime) may consider leveraging null contribution verification as it is done in copy<NEW_LINE>UnconditionalFlowInfo copy = new UnconditionalFlowInfo();<NEW_LINE>copy.tagBits = this.tagBits;<NEW_LINE>copy.maxFieldCount = this.maxFieldCount;<NE... | = new long[extraLength][]; |
1,037,127 | private Image annotateImage(Image image) {<NEW_LINE>Image icon = image;<NEW_LINE>boolean badged = false;<NEW_LINE>// platform providers<NEW_LINE>for (PlatformProvider provider : project.getPlatformProviders()) {<NEW_LINE><MASK><NEW_LINE>if (badgeIcon != null) {<NEW_LINE>icon = ImageUtilities.addToolTipToImage(icon, Str... | BadgeIcon badgeIcon = provider.getBadgeIcon(); |
1,408,371 | private Button renderDefaultOverflowAction(@NonNull Context context, @NonNull ViewGroup viewGroup, @NonNull HostConfig hostConfig) {<NEW_LINE>final Button overflowActionView = new Button(context);<NEW_LINE>LinearLayout.LayoutParams layoutParams;<NEW_LINE>final ActionsOrientation orientation = hostConfig.GetActions().ge... | Util.dpToPixels(context, OVERFLOW_BUTTON_WIDTH); |
94,482 | protected URI parseValue(Object obj) throws ParameterException {<NEW_LINE>if (obj == null) {<NEW_LINE>throw new UnspecifiedParameterException(this);<NEW_LINE>}<NEW_LINE>if (obj instanceof URI) {<NEW_LINE>return (URI) obj;<NEW_LINE>}<NEW_LINE>if (obj instanceof URL) {<NEW_LINE>try {<NEW_LINE>return ((URL) obj).toURI();<... | get(str).toUri(); |
63,844 | public AlgorithmVersionInfoList requestAlgorithms(String xSdsAuthToken) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String localVarPath = "/v4/config/info/policies/algorithms";<NEW_LINE>// query params<NEW_LINE>List<Pair> localVarQueryParams = new Ar... | localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
1,553,136 | public boolean insertOpenedTopComponent(TopComponent tc, int index) {<NEW_LINE>if (index >= 0 && !openedTopComponents.isEmpty() && openedTopComponents.size() > index && openedTopComponents.get(index) == tc) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>// Remove from previous index<NEW_LINE>openedTopComponents.remove(tc... | openedTopComponents.add(position, tc); |
1,651,205 | private void bubbleSort() {<NEW_LINE>List<String> labels = mChart.getData().getXVals();<NEW_LINE>List<Entry> values = mChart.getData().getDataSet().getYVals();<NEW_LINE>List<Integer> colors = mChart.getData().getDataSet().getColors();<NEW_LINE>float tmp1;<NEW_LINE>String tmp2;<NEW_LINE>Integer tmp3;<NEW_LINE>for (int i... | labels.get(j - 1); |
1,449,990 | public void onBindViewHolder(@NonNull final MapMarkerItemViewHolder holder, int position) {<NEW_LINE>WptPt wpt = getItem(position);<NEW_LINE>holder.iconDirection.setVisibility(View.VISIBLE);<NEW_LINE>holder.icon.setImageDrawable(PointImageDrawable.getFromWpt(app, wpt.getColor(), false, wpt));<NEW_LINE>holder.mainLayout... | : R.color.divider_color_light)); |
1,582,229 | private void saveWorkflowTaskInternal(final WorkflowTask task, final WorkflowProcessor processor, final boolean doIndex) throws DotDataException {<NEW_LINE>if (doIndex) {<NEW_LINE>this.saveWorkflowTask(task);<NEW_LINE>} else {<NEW_LINE>this.saveWorkflowTaskWithoutIndexing(task);<NEW_LINE>}<NEW_LINE>final WorkflowHistor... | , nextAssignName, comment }, false); |
1,035,405 | public ListTableMetadataResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ListTableMetadataResult listTableMetadataResult = new ListTableMetadataResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LI... | )).unmarshall(context)); |
1,585,736 | private static Function checkInsideThunkFunction(Program program, Address address, TaskMonitor monitor) throws CancelledException {<NEW_LINE><MASK><NEW_LINE>Function thunkFunction = listing.getFunctionContaining(address);<NEW_LINE>if (thunkFunction == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>if (thunkFunction.... | Listing listing = program.getListing(); |
182,626 | public static ListCityMapImageDetailsResponse unmarshall(ListCityMapImageDetailsResponse listCityMapImageDetailsResponse, UnmarshallerContext _ctx) {<NEW_LINE>listCityMapImageDetailsResponse.setRequestId(_ctx.stringValue("ListCityMapImageDetailsResponse.RequestId"));<NEW_LINE>listCityMapImageDetailsResponse.setCode(_ct... | ("ListCityMapImageDetailsResponse.Data[" + i + "].CoatColor")); |
227,220 | private void applyVerticalTransition() {<NEW_LINE>if (mCollapsibleHeightForRecommendation > 0) {<NEW_LINE>int yDisplacement = Math.<MASK><NEW_LINE>mViewHolder.mHeaderTitle.setTranslationY(yDisplacement);<NEW_LINE>mViewHolder.mRecommendedWidgetsTable.setTranslationY(yDisplacement);<NEW_LINE>}<NEW_LINE>if (mCollapsibleHe... | max(-mCurrentRecyclerViewScrollY, -mCollapsibleHeightForRecommendation); |
5,598 | private static SaveKeyringParcel createDefaultSaveKeyringParcel(CreateKeyActivity createKeyActivity) {<NEW_LINE>SaveKeyringParcel.Builder builder = SaveKeyringParcel.buildNewKeyringParcel();<NEW_LINE>if (createKeyActivity.mCreateSecurityToken) {<NEW_LINE>if (createKeyActivity.mSecurityTokenSign == null) {<NEW_LINE>crea... | KeyFlags.ENCRYPT_COMMS | KeyFlags.ENCRYPT_STORAGE); |
457,225 | public void addMessagesToGroup(Object groupId, Message<?>... messages) {<NEW_LINE>String groupKey = getKey(groupId);<NEW_LINE>MessageGroupMetadata groupMetadata = getGroupMetadata(groupKey);<NEW_LINE>boolean groupNotExist = groupMetadata == null;<NEW_LINE>Timestamp createdDate = groupNotExist ? new Timestamp(System.cur... | 3, JdbcMessageStore.this.region); |
519,113 | ActionResult<Wo> execute(EffectivePerson effectivePerson, String flag, JsonElement jsonElement) throws Exception {<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>ActionResult<Wo> result = new ActionResult<>();<NEW_LINE>Business business = new Business(emc);<NEW_... | ExceptionEntityClass(statement.getEntityClassName()); |
76,725 | private void _selfWriteRangeImpl(int toElement, int count, int fromElement, boolean bForward, int stride) {<NEW_LINE>// writing from to this stream.<NEW_LINE>if (bForward) {<NEW_LINE>if (toElement == fromElement)<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>int offset;<NEW_LINE>int j;<NEW_LINE>int dj;<NEW_LINE>if (fromElement ... | [j] = m_buffer[offset]; |
1,751,253 | Proximity2DResult multiPathGetNearestCoordinate(MultiPath geom, Point2D inputPoint, boolean bTestPolygonInterior, boolean bCalculateLeftRightSide) {<NEW_LINE>if (geom.getType() == Geometry.Type.Polygon && bTestPolygonInterior) {<NEW_LINE>Envelope2D env = new Envelope2D();<NEW_LINE>geom.queryEnvelope2D(env);<NEW_LINE>do... | Proximity2DResult(inputPoint, 0, 0.0); |
152,551 | private void runAlterJobWithConcurrencyLimit(RollupJobV2 rollupJobV2) {<NEW_LINE>if (rollupJobV2.isDone()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (rollupJobV2.isTimeout()) {<NEW_LINE>// in run(), the timeout job will be cancelled.<NEW_LINE>rollupJobV2.run();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// check if rollup jo... | long tblId = rollupJobV2.getTableId(); |
1,375,600 | public ProtocolTransportObject fromCloudEvent(CloudEvent cloudEvent) throws ProtocolHandleException {<NEW_LINE>String protocolDesc = cloudEvent.getExtension(Constants.PROTOCOL_DESC).toString();<NEW_LINE>if (StringUtils.equals("http", protocolDesc)) {<NEW_LINE>HttpCommand httpCommand = new HttpCommand();<NEW_LINE>Body b... | (), StandardCharsets.UTF_8)); |
642,372 | final ListResourceDataSyncResult executeListResourceDataSync(ListResourceDataSyncRequest listResourceDataSyncRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listResourceDataSyncRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRe... | false), new ListResourceDataSyncResultJsonUnmarshaller()); |
568,730 | public DescribeDefaultAuthorizerResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeDefaultAuthorizerResult describeDefaultAuthorizerResult = new DescribeDefaultAuthorizerResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int t... | int originalDepth = context.getCurrentDepth(); |
1,759,037 | public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {<NEW_LINE>super.<MASK><NEW_LINE>sharedPrefs = context.getSharedPreferences("com.klinker.android.twitter_world_preferences", 0);<NEW_LINE>settings = AppSettings.getInstance(context);<NEW_LINE>layout = inflater.inflate(R.la... | onCreateView(inflater, container, savedInstanceState); |
507,056 | public ParamType toFunctionType(final SqlType sqlType) {<NEW_LINE>final ParamType paramType = FunctionToSql.FUNCTION_TO_SQL.inverse().get(sqlType);<NEW_LINE>if (paramType != null) {<NEW_LINE>return paramType;<NEW_LINE>}<NEW_LINE>if (sqlType.baseType() == SqlBaseType.DECIMAL) {<NEW_LINE>return ParamTypes.DECIMAL;<NEW_LI... | (field.type())); |
398,222 | private void loadNode33() throws IOException, SAXException {<NEW_LINE>DataTypeDescriptionTypeNode node = new DataTypeDescriptionTypeNode(this.context, Identifiers.OpcUa_XmlSchema_UserNameIdentityToken, new QualifiedName(0, "UserNameIdentityToken"), new LocalizedText("en", "UserNameIdentityToken"), LocalizedText.NULL_VA... | String xml = sb.toString(); |
1,510,176 | public static VmwareDistributedVirtualSwitchVlanSpec createDVPortVlanSpec(Integer vlanId, String vlanRange) {<NEW_LINE>if (vlanId != null && vlanId == 4095) {<NEW_LINE>vlanId = null;<NEW_LINE>vlanRange = "0-4094";<NEW_LINE>}<NEW_LINE>if (vlanId == null && vlanRange != null && !vlanRange.isEmpty()) {<NEW_LINE>s_logger.d... | final NumericRange numericRange = new NumericRange(); |
74,459 | protected void checkTables() throws SQLException {<NEW_LINE>setCreateH2StringsMap(tableNames);<NEW_LINE>createTableIfNotExists(tableNames.get(CHECKPOINT_TABLE_KEY), createH2Strings.get(H2_CREATE_TABLE_CHECKPOINTDATA));<NEW_LINE>createTableIfNotExists(tableNames.get(JOB_INSTANCE_TABLE_KEY), createH2Strings.get(H2_CREATE... | , createH2Strings.get(H2_CREATE_TABLE_STEPSTATUS)); |
1,715,188 | public int intrinsicIndexOfStringLatin1(Object s1Value, int s1len, Object s2Value, int s2len, int start) {<NEW_LINE>char firstChar = byteToCharUnsigned(getByteFromArrayByIndex(s2Value, 0));<NEW_LINE>while (true) {<NEW_LINE>int i = intrinsicIndexOfLatin1(s1Value, (byte) firstChar, start, s1len);<NEW_LINE>// Handles subC... | == getByteFromArrayByIndex(s2Value, o2)) ; |
849,531 | static ASTNode findContainingNode(@Nonnull PsiFile file, @Nullable TextRange range) {<NEW_LINE>Language language = file.getLanguage();<NEW_LINE>if (range == null)<NEW_LINE>return null;<NEW_LINE>final FileViewProvider viewProvider = file.getViewProvider();<NEW_LINE>final PsiElement startElement = viewProvider.findElemen... | range.getStartOffset(), language); |
961,383 | final DeleteClusterResult executeDeleteCluster(DeleteClusterRequest deleteClusterRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteClusterRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
1,467,760 | public static JSONObject fillTemplate(JSONObject questionJson, Map<String, JsonNode> parameters, String questionName) throws JSONException, IOException {<NEW_LINE>// deep copy<NEW_LINE>JSONObject clonedQuestionJson = new <MASK><NEW_LINE>JSONObject instanceJson = clonedQuestionJson.getJSONObject(BfConsts.PROP_INSTANCE);... | JSONObject(questionJson.toString()); |
967,166 | public com.amazonaws.services.logs.model.InvalidSequenceTokenException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.logs.model.InvalidSequenceTokenException invalidSequenceTokenException = new com.amazonaws.services.logs.model.InvalidSequenceTokenException(nu... | String currentParentElement = context.getCurrentParentElement(); |
1,298,810 | public List<ContentType> recentlyUsed(BaseContentType type, int numberToShow) throws DotDataException {<NEW_LINE>String query = " { \"query\": { \"query_string\": { \"query\": \"+moduser:{0} +working:true +deleted:false +basetype:{1}\" } }, \"aggs\": { \"recent-contents\": { \"terms\": { \"field\": \"contentType_dotra... | ), false, user, false); |
1,734,983 | protected void run() throws GitException {<NEW_LINE>Repository repository = getRepository();<NEW_LINE>org.eclipse.jgit.api.RebaseCommand command = new Git(repository).rebase();<NEW_LINE>if (operation == GitClient.RebaseOperationType.BEGIN) {<NEW_LINE>Ref ref = null;<NEW_LINE>try {<NEW_LINE>ref = repository.findRef(revi... | setUpstreamName(ref.getName()); |
464,492 | public static void deleteHeapTempFiles() {<NEW_LINE>if (Platform.isWindows()) {<NEW_LINE>// this is workaroud for JDK bug #6359560<NEW_LINE>try {<NEW_LINE>// NOI18N<NEW_LINE>File tempDir = new File(System.getProperty("java.io.tmpdir"));<NEW_LINE>DirectoryStream<Path> files = Files.newDirectoryStream(tempDir.toPath());<... | System.err.println("deleteHeapTempFiles failed"); |
737,072 | public boolean restartNetwork(final Long networkId, final Account callerAccount, final User callerUser, final boolean cleanup) throws ConcurrentOperationException, ResourceUnavailableException, InsufficientCapacityException {<NEW_LINE>boolean status = true;<NEW_LINE>boolean restartRequired = false;<NEW_LINE>final Netwo... | ), null, null, null); |
1,035,642 | public static GetPipelineInstanceBuildNumberStatusResponse unmarshall(GetPipelineInstanceBuildNumberStatusResponse getPipelineInstanceBuildNumberStatusResponse, UnmarshallerContext _ctx) {<NEW_LINE>getPipelineInstanceBuildNumberStatusResponse.setRequestId(_ctx.stringValue("GetPipelineInstanceBuildNumberStatusResponse.R... | + "].Stages[" + j + "].Status")); |
1,290,422 | final GetTestGridProjectResult executeGetTestGridProject(GetTestGridProjectRequest getTestGridProjectRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getTestGridProjectRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
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... | SignedCertificateTimestampSignature signature = signatureParser.parse(); |
1,245,433 | protected void fireReadSelect() {<NEW_LINE>try {<NEW_LINE>synchronized (this) {<NEW_LINE>if (read_listener != null && !read_selects_paused) {<NEW_LINE>if (failed != null) {<NEW_LINE>selector.ready(<MASK><NEW_LINE>} else if (closed) {<NEW_LINE>selector.ready(this, read_listener, read_attachment, new Throwable("Transport... | this, read_listener, read_attachment, failed); |
970,775 | protected JFreeChart createScatterChart() throws JRException {<NEW_LINE><MASK><NEW_LINE>XYPlot xyPlot = (XYPlot) jfreeChart.getPlot();<NEW_LINE>xyPlot.setRangeGridlinePaint(SCATTER_GRIDLINE_COLOR);<NEW_LINE>xyPlot.setRangeGridlineStroke(new BasicStroke(0.75f));<NEW_LINE>xyPlot.setDomainGridlinesVisible(true);<NEW_LINE>... | JFreeChart jfreeChart = super.createScatterChart(); |
342,658 | private AuthenticationStatus handleAuthorizationHeader(String authHeader, Subject clientSubject, HttpMessageContext httpMessageContext) throws AuthenticationException {<NEW_LINE>AuthenticationStatus status = AuthenticationStatus.SEND_FAILURE;<NEW_LINE>int rspStatus = HttpServletResponse.SC_FORBIDDEN;<NEW_LINE>// the fo... | values = authHeader.split(":"); |
825,279 | public List<PrimaryStorageInventory> allocateAllCandidates(PrimaryStorageAllocationSpec spec) {<NEW_LINE>class Result {<NEW_LINE><NEW_LINE>List<PrimaryStorageVO> result;<NEW_LINE><NEW_LINE>ErrorCode errorCode;<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>FlowChain allocatorChain = builder.build();<NEW_LINE>allocatorChain.setNam... | final Result ret = new Result(); |
679,804 | final TestEventPatternResult executeTestEventPattern(TestEventPatternRequest testEventPatternRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(testEventPatternRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
1,393,876 | final CancelQueryResult executeCancelQuery(CancelQueryRequest cancelQueryRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(cancelQueryRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | addHandlerContext(HandlerContextKey.SERVICE_ID, "Timestream Query"); |
79,617 | public void run() throws Exception {<NEW_LINE>initializeOutputDir();<NEW_LINE>IOUtil.checkDirectoryArgument(modelRoot, "Model Root");<NEW_LINE>IOUtil.checkFileArgument(inputPath, "Input File");<NEW_LINE>Path out = outDir.resolve(inputPath.toFile().getName() + ".ne");<NEW_LINE>List<String> lines = Files.readAllLines(inp... | Log.info("Result is written in %s", out); |
1,481,121 | public static void layoutColumns(JTable p_Table, boolean p_OnlyVisibleRows) {<NEW_LINE>int column = 0;<NEW_LINE>TableColumn c = null;<NEW_LINE>int firstRow = <MASK><NEW_LINE>int lastRow = p_OnlyVisibleRows ? getLastVisibleRow(p_Table) : (p_Table.getModel().getRowCount() - 1);<NEW_LINE>Dimension intercellSpacing = p_Tab... | p_OnlyVisibleRows ? getFirstVisibleRow(p_Table) : 0; |
1,456,239 | public static void updateSpeedTabInfo(@NonNull View container, @NonNull OsmandApplication app, @NonNull GPXTrackAnalysis analysis, boolean joinSegments, boolean generalTrack) {<NEW_LINE>long timeMoving = !joinSegments && generalTrack ? analysis.timeMovingWithoutGaps : analysis.timeMoving;<NEW_LINE>float totalDistanceMo... | findViewById(R.id.average_text); |
1,014,777 | private static void createReference(AnnotationModelHelper helper, TypeElement interfaceTypeElement, List<EjbRef> resultEjbRefs, List<EjbLocalRef> resultEjbLocalRefs, String name, String beanInterface, String beanName, String mappedName, String description) {<NEW_LINE>// TODO: implement good-enough algorithm to recogniz... | getAnnotationsByType(interfaceTypeElement.getAnnotationMirrors()); |
113,735 | private Mono<PagedResponse<PrivateEndpointInner>> listByResourceGroupSinglePageAsync(String resourceGroupName, Context context) {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.<MASK><NEW_LINE>}<NEW_LINE>if (resourceGroupName == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Pa... | error(new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null.")); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.