idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
865,511 | public static void splitLongFloatVector(KeyHash hasher, MatrixMeta matrixMeta, LongFloatVector vector, KeyValuePart[] dataParts) {<NEW_LINE>int dataPartNum = dataParts.length;<NEW_LINE>int dataPartNumMinus1 = dataPartNum - 1;<NEW_LINE>if (isPow2(dataPartNum)) {<NEW_LINE>LongFloatVectorStorage storage = vector.getStorag... | > iter = sparseStorage.entryIterator(); |
1,408,367 | public Future<HttpResponse> doAsyncHttp(String type, String path, String dataStr, Map<String, String> head, GrafanaHttpCallBack callback) {<NEW_LINE>Future<HttpResponse> response = null;<NEW_LINE>// def callback<NEW_LINE>if (null == callback) {<NEW_LINE>callback = new GrafanaHttpCallBack(configMap);<NEW_LINE>}<NEW_LINE... | head.putAll(getHttpReqHead()); |
351,121 | public <T> Mono<ReactiveSearchHits<T>> searchForHits(Query query, Class<?> entityType, Class<T> resultType, IndexCoordinates index) {<NEW_LINE>Assert.notNull(query, "query must not be null");<NEW_LINE>Assert.notNull(entityType, "entityType must not be null");<NEW_LINE>Assert.notNull(resultType, "resultType must not be ... | ).map(ReactiveSearchHitSupport::searchHitsFor); |
969,202 | public GlobalId createId(Object targetCdo, OwnerContext ownerContext) {<NEW_LINE>Validate.argumentsAreNotNull(targetCdo);<NEW_LINE>Optional<ObjectAccessProxy> cdoProxy = objectAccessHook.createAccessor(targetCdo);<NEW_LINE>Class<?> targetClass = cdoProxy.map((p) -> p.getTargetClass()).orElse(targetCdo.getClass());<NEW_... | parentFragment.get() + localPath); |
1,392,623 | public void voteUpArticle(final RequestContext context) {<NEW_LINE>context.renderJSON(StatusCodes.ERR);<NEW_LINE>final JSONObject requestJSONObject = context.requestJSON();<NEW_LINE>final String dataId = requestJSONObject.optString(Common.DATA_ID);<NEW_LINE>final JSONObject currentUser = Sessions.getUser();<NEW_LINE>fi... | userId, dataId, Vote.DATA_TYPE_C_ARTICLE); |
1,178,232 | private void generateKeyPairs() {<NEW_LINE>try {<NEW_LINE>final ECNamedCurveParameterSpec parameterSpec = ECNamedCurveTable.getParameterSpec("secp256r1");<NEW_LINE>final KeyPairGenerator keyPairGenerator = KeyPairGenerator.getInstance("ECDH", "SC");<NEW_LINE>keyPairGenerator.initialize(parameterSpec);<NEW_LINE>final Ke... | BigIntegers.asUnsignedByteArray(32, x); |
1,374,476 | public Object execute(Value... arguments) {<NEW_LINE>final CacheExpression cacheExpr <MASK><NEW_LINE>Object retVal = null;<NEW_LINE>Object[] parameters = Arrays.stream(arguments).map(a -> PolyglotWrapper.unwrap(actionContext, a)).toArray();<NEW_LINE>try {<NEW_LINE>for (Object parameter : parameters) {<NEW_LINE>if (para... | = new CacheExpression(1, 1); |
1,124,137 | private void logRoutes() {<NEW_LINE>// determine the width of the columns<NEW_LINE>int maxMethodLen = 0;<NEW_LINE>int maxPathLen = 0;<NEW_LINE>int maxControllerLen = 0;<NEW_LINE>for (Route route : getRoutes()) {<NEW_LINE>maxMethodLen = Math.max(maxMethodLen, route.getHttpMethod().length());<NEW_LINE>maxPathLen = Math.m... | getControllerMethod().getName()); |
43,726 | public void replaceText(int start, int end, String text) {<NEW_LINE>if (start > 0 && end > 0) {<NEW_LINE>int s = Math.max(0, start - 1);<NEW_LINE>int e = Math.min(end + 1, getLength() - 1);<NEW_LINE>List<Either<String, Hyperlink>> segList = getDocument().subSequence(s, e).getParagraph(0).getSegments();<NEW_LINE>if (!se... | start, end, text, link); |
494,085 | public void validateDiskOfferingUserConfig(String userConfig, String diskOfferingUuid) {<NEW_LINE>if (StringUtils.isBlank(userConfig)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>DiskOfferingUserConfig config;<NEW_LINE>try {<NEW_LINE>config = OfferingUserConfigUtils.toObject(userConfig, DiskOfferingUserConfig.class);<NEW_LI... | .getAllocate().getPrimaryStorage(); |
1,096,292 | private boolean processPayment(HttpServletRequest request, Properties ctx, MPayment payment, WebUser wu, WebOrder wo) {<NEW_LINE>boolean ok = processParameter(request, ctx, payment, wu);<NEW_LINE>if (ok) {<NEW_LINE>// if negative amount - make it positive<NEW_LINE>if (payment.getPayAmt().compareTo(Env.ZERO) < 0)<NEW_LI... | fine(payment.getErrorMessage()); |
922,420 | public void onCloseActivityFinal(final Runnable run) {<NEW_LINE>stopTimer();<NEW_LINE>TTSEngine.get().stop();<NEW_LINE>TTSNotification.hideNotification();<NEW_LINE>Safe.run(new Runnable() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void run() {<NEW_LINE>isClosed = true;<NEW_LINE>if (codeDocument != null) {<NEW_LINE>... | putExtra("page", getCurentPage()); |
1,673,766 | public static void main(String[] args) throws Exception {<NEW_LINE>WordprocessingMLPackage wordMLPackage = WordprocessingMLPackage.createPackage();<NEW_LINE>String outputfilepath = System.getProperty("user.dir") + "/OUT_bookmarkAdd.docx";<NEW_LINE>;<NEW_LINE>wordMLPackage.<MASK><NEW_LINE>wordMLPackage.getMainDocumentPa... | getMainDocumentPart().addParagraphOfText("x"); |
578,644 | private void doAssert(Map<String, String> expected, PlaybackContext context) throws AssertionError {<NEW_LINE>final Component owner = KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusOwner();<NEW_LINE>if (owner == null) {<NEW_LINE>throw new AssertionError("No component focused");<NEW_LINE>}<NEW_LINE>Compon... | , actual.get(eachKey)); |
1,228,238 | public static void writeSearchRequestParams(SearchRequest request, XContentBuilder xContentBuilder) throws IOException {<NEW_LINE>xContentBuilder.startObject();<NEW_LINE>if (request.indices() != null) {<NEW_LINE>xContentBuilder.field("index", request.indices());<NEW_LINE>}<NEW_LINE>if (request.indicesOptions() != null ... | xContentBuilder.field("expand_wildcards", "all"); |
8,675 | public Builder mergeFrom(emu.grasscutter.net.proto.EntityAuthorityInfoOuterClass.EntityAuthorityInfo other) {<NEW_LINE>if (other == emu.grasscutter.net.proto.EntityAuthorityInfoOuterClass.EntityAuthorityInfo.getDefaultInstance())<NEW_LINE>return this;<NEW_LINE>if (other.hasAbilityInfo()) {<NEW_LINE>mergeAbilityInfo(oth... | mergeAiInfo(other.getAiInfo()); |
881,990 | /*<NEW_LINE>* RunningQuery factory.<NEW_LINE>*/<NEW_LINE>@SuppressWarnings("unchecked")<NEW_LINE>protected AbstractRunningQuery newRunningQuery(/*final QueryEngine queryEngine,*/<NEW_LINE>final UUID queryId, final boolean controller, final IQueryClient clientProxy, final UUID queryControllerId, final PipelineOp query, ... | Annotations.RUNNING_QUERY_CLASS, Annotations.DEFAULT_RUNNING_QUERY_CLASS); |
36,795 | public ListPublishedSchemaArnsResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ListPublishedSchemaArnsResult listPublishedSchemaArnsResult = new ListPublishedSchemaArnsResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurren... | class).unmarshall(context)); |
982,900 | private boolean isMemberOfPrivacyGroup(final boolean isAddingParticipant, final PrivateTransaction privateTransaction, final Bytes privateFrom, final FlexiblePrivacyGroupContract flexiblePrivacyGroupContract, final Bytes32 privacyGroupId) {<NEW_LINE>final List<String> members = flexiblePrivacyGroupContract.getPrivacyGr... | getParticipantsFromParameter(privateTransaction.getPayload()); |
675,102 | static void exportStructure(Context context, OutputStream output) {<NEW_LINE>// Build a document from the Community/Collection hierarchy.<NEW_LINE>// To be read by importStructure, perhaps<NEW_LINE><MASK><NEW_LINE>List<Community> communities = null;<NEW_LINE>try {<NEW_LINE>communities = communityService.findAllTop(cont... | Element rootElement = new Element(INPUT_ROOT); |
486,608 | private <T extends Trait> OpenApi convertWithEnvironment(ConversionEnvironment<T> environment) {<NEW_LINE>ServiceShape service = environment.context.getService();<NEW_LINE>Context<T> context = environment.context;<NEW_LINE>OpenApiMapper mapper = environment.mapper;<NEW_LINE>OpenApiProtocol<T> openApiProtocol <MASK><NEW... | = environment.context.getOpenApiProtocol(); |
1,464,764 | private String imagingStudy(RandomNumberGenerator rand, String personID, String encounterID, ImagingStudy imagingStudy) throws IOException {<NEW_LINE>// Id,DATE,PATIENT,ENCOUNTER,SERIES_UID,BODYSITE_CODE,BODYSITE_DESCRIPTION,<NEW_LINE>// MODALITY_CODE,MODALITY_DESCRIPTION,INSTANCE_UID,SOP_CODE,SOP_DESCRIPTION,PROCEDURE... | .code).append(','); |
865,617 | private // ------------------------------------------------------------------------<NEW_LINE>void checkJodaSetGetYear() {<NEW_LINE>int COUNT = COUNT_FAST;<NEW_LINE>// Is it fair to use only MutableDateTime here? You decide.<NEW_LINE>// MutableDateTime dt = new MutableDateTime(GJChronology.getInstance());<NEW_LINE>// fo... | int val = dt.getYear(); |
608,033 | public void addParent(MProductBOM bom, DefaultMutableTreeNode parent) {<NEW_LINE>MProduct M_Product = MProduct.get(getCtx(), bom.getM_Product_ID());<NEW_LINE>Vector<Object> line = new Vector<Object>(17);<NEW_LINE>// 0 Select<NEW_LINE>line.add(new Boolean(false));<NEW_LINE>// 1 IsActive<NEW_LINE>line.add(new Boolean(M_P... | ), M_Product.get_TrxName()); |
1,307,278 | public void actionPerformed(ActionEvent e) {<NEW_LINE>String searchID = e.getActionCommand();<NEW_LINE>int modelRow = TablesUtil.findTableRowFromSearchId(matchesModel, searchID);<NEW_LINE>if (modelRow == -1) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>String action = (String) matchesModel.getValueAt(modelRow, MatchesTableMo... | getDesktop().getMousePosition()); |
594,793 | public static IdentityProviderRepresentation toRepresentation(RealmModel realm, IdentityProviderModel identityProviderModel) {<NEW_LINE>IdentityProviderRepresentation providerRep = new IdentityProviderRepresentation();<NEW_LINE>providerRep.setInternalId(identityProviderModel.getInternalId());<NEW_LINE>providerRep.setPr... | setFirstBrokerLoginFlowAlias(flow.getAlias()); |
699,061 | final StopActivityStreamResult executeStopActivityStream(StopActivityStreamRequest stopActivityStreamRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(stopActivityStreamRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW_LINE... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
25,554 | final UpdateScalingParametersResult executeUpdateScalingParameters(UpdateScalingParametersRequest updateScalingParametersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateScalingParametersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
592,930 | public static void showInstallerUpdateNotification() {<NEW_LINE>Intent intent = new Intent(sContext, WelcomeActivity.class);<NEW_LINE>intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);<NEW_LINE>intent.putExtra(FRAGMENT_ID, 0);<NEW_LINE>PendingIntent pInstallTab = PendingIntent.getActivity(sContext, PENDING_INTENT_OPEN_INS... | notiStyle = new NotificationCompat.BigTextStyle(); |
746,978 | final ListUserTagsResult executeListUserTags(ListUserTagsRequest listUserTagsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listUserTagsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | addHandlerContext(HandlerContextKey.SERVICE_ID, "IAM"); |
1,705,917 | private BigDecimal retrieveAllocatedAmt(final int invoiceId, final String trxName) {<NEW_LINE>BigDecimal retValue = null;<NEW_LINE>final String sql = "SELECT SUM(currencyConvert(al.Amount+al.DiscountAmt+al.WriteOffAmt," + "ah.C_Currency_ID, i.C_Currency_ID,ah.DateTrx,COALESCE(i.C_ConversionType_ID,0), al.AD_Client_ID,a... | throw new DBException(e, sql); |
1,409,520 | public static DescribeEcsListPageResponse unmarshall(DescribeEcsListPageResponse describeEcsListPageResponse, UnmarshallerContext context) {<NEW_LINE>describeEcsListPageResponse.setRequestId(context.stringValue("DescribeEcsListPageResponse.RequestId"));<NEW_LINE>describeEcsListPageResponse.setModule(context.stringValue... | ("DescribeEcsListPageResponse.DataList[" + i + "].InstanceName")); |
1,435,540 | private Map<String, MutableHitCount> computeHitCount(EventQueryDefinition query, String pColName) {<NEW_LINE>Map<String, MutableHitCount> hitCount = new HashMap<String, MutableHitCount>();<NEW_LINE>try (Connection hbConn = ConnectionFactory.createConnection(conn.getConfig())) {<NEW_LINE>try (Table table = hbConn.getTab... | AuditAccessException("Compute hitcount based on " + pColName, e); |
1,089,854 | public boolean action(Request request, Response response) {<NEW_LINE>if (request.getNettyRequest() instanceof FullHttpRequest) {<NEW_LINE>SendMessageData sendMessageData = getRequestBody(request.getNettyRequest(), SendMessageData.class);<NEW_LINE>sendMessageData.<MASK><NEW_LINE>if (SendMessageData.isValide(sendMessageD... | setSender(robot.getUid()); |
586,161 | public static void horizontal3(Kernel1D_S32 kernel, GrayS16 image, GrayI16 dest, int divisor) {<NEW_LINE>final short[] dataSrc = image.data;<NEW_LINE>final short[] dataDst = dest.data;<NEW_LINE>final int k1 = kernel.data[0];<NEW_LINE>final int k2 = kernel.data[1];<NEW_LINE>final int k3 = kernel.data[2];<NEW_LINE>final ... | (dataSrc[indexSrc]) * k3; |
919,491 | public static DescribeNetworkAttributeResponse unmarshall(DescribeNetworkAttributeResponse describeNetworkAttributeResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeNetworkAttributeResponse.setRequestId(_ctx.stringValue("DescribeNetworkAttributeResponse.RequestId"));<NEW_LINE>describeNetworkAttributeResponse.setEn... | ("DescribeNetworkAttributeResponse.CloudResources[" + i + "].ResourceCount")); |
451,768 | private Locale determineLocale(HttpServletRequest request, Site site) {<NEW_LINE>Locale locale = null;<NEW_LINE>// First check for request attribute<NEW_LINE>locale = (Locale) request.getAttribute(LOCALE_VAR);<NEW_LINE>// Second, check for a request parameter<NEW_LINE>if (locale == null && request.getParameter(LOCALE_C... | HashMap<String, Object>(); |
1,588,662 | private MethodTree genJAXP_ParseURLMethod(TreeMaker make) {<NEW_LINE>// NOI18N<NEW_LINE>String parsletParam = model<MASK><NEW_LINE>StringBuffer sb = new StringBuffer("{");<NEW_LINE>sb.append("\n" + M_PARSE + "(new " + SAX_INPUT_SOURCE + "(url.toExternalForm()), handler" + parsletParam + ");");<NEW_LINE>sb.append("}\n")... | .hasParslets() ? ", parslet" : ""; |
191,177 | protected void onPreDraw(long timestampUs, @NonNull float[] transformMatrix) {<NEW_LINE>super.onPreDraw(timestampUs, transformMatrix);<NEW_LINE>float[] scale = new float[2];<NEW_LINE>if (mWidth > mHeight) {<NEW_LINE>scale[0] = 1f;<NEW_LINE>scale[1] = ((float) mHeight) / mWidth;<NEW_LINE>} else {<NEW_LINE>scale[0] = ((f... | GLES20.glUniform1f(mShadeLocation, mShade); |
350,763 | private boolean tryUsingGenerator(MethodHolder method) {<NEW_LINE>MethodReference methodRef = method.getReference();<NEW_LINE>Generator generator = context.getGenerator(methodRef);<NEW_LINE>if (generator == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>generateMethodForwardDeclaration(method);<NEW_LINE>CodeWriter ... | CodeWriter bodyWriter = codeWriter.fragment(); |
1,597,159 | private Composite buildHelp(Composite rhs) {<NEW_LINE>boolean public_chat = !chat.isPrivateChat();<NEW_LINE>boolean sharing_view = chat.getViewType() == BuddyPluginBeta.VIEW_TYPE_SHARING;<NEW_LINE>boolean can_popout = shell == null && public_chat;<NEW_LINE>Composite top_right = new Composite(rhs, SWT.NONE);<NEW_LINE>Gr... | Label(top_right, SWT.NULL); |
1,646,881 | private Object createServiceProxy(Contract contract, JvmBinding binding, SofaRuntimeContext sofaRuntimeContext) {<NEW_LINE>ClassLoader newClassLoader;<NEW_LINE>ClassLoader appClassLoader = sofaRuntimeContext.getAppClassLoader();<NEW_LINE>Class<?> javaClass = contract.getInterfaceType();<NEW_LINE>try {<NEW_LINE>Class ap... | currentThread().setContextClassLoader(newClassLoader); |
350,714 | public GameSessionDetail unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GameSessionDetail gameSessionDetail = new GameSessionDetail();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = ori... | ().unmarshall(context)); |
1,304,304 | public static Class<?> toClassWeld3(Object proxyFactory, ClassFile ct, Class<?> originalClass, ProxyServices proxyServices, ProtectionDomain domain) {<NEW_LINE>if (MAGIC_IN_PROGRESS.get()) {<NEW_LINE>try {<NEW_LINE>ClassLoader loader = originalClass.getClassLoader();<NEW_LINE>if (loader == null) {<NEW_LINE>loader = Thr... | originalProxyClass, ct.toBytecode()); |
650,738 | public static QuerySupplementInfoListResponse unmarshall(QuerySupplementInfoListResponse querySupplementInfoListResponse, UnmarshallerContext _ctx) {<NEW_LINE>querySupplementInfoListResponse.setRequestId(_ctx.stringValue("QuerySupplementInfoListResponse.RequestId"));<NEW_LINE>querySupplementInfoListResponse.setSuccess(... | ("QuerySupplementInfoListResponse.Data[" + i + "].SupplementId")); |
1,160,409 | private void validate() {<NEW_LINE>boolean flag = revisionValid && (Boolean.TRUE.equals(nameValid) || panel.cbForceUpdate.isEnabled() && panel.cbForceUpdate.isSelected());<NEW_LINE>if (!flag && revisionValid) {<NEW_LINE>String tName = getTagName();<NEW_LINE>if (tName.isEmpty() || !GitUtils.isValidTagName(tName)) {<NEW_... | (CreateTag.class, "MSG_CreateTag.infoLightWeightTag")); |
23,454 | private V slowReplace(K key, V value, int hash, Object[] currentArray) {<NEW_LINE>// noinspection LabeledStatement<NEW_LINE>outer: while (true) {<NEW_LINE>int length = currentArray.length;<NEW_LINE>int index = ConcurrentHashMapUnsafe.indexFor(hash, length);<NEW_LINE>Object o = <MASK><NEW_LINE>if (o == RESIZED || o == R... | ConcurrentHashMapUnsafe.arrayAt(currentArray, index); |
1,143,190 | public static RemovePrivilegesFromRoleResponse unmarshall(RemovePrivilegesFromRoleResponse removePrivilegesFromRoleResponse, UnmarshallerContext context) {<NEW_LINE>removePrivilegesFromRoleResponse.setRequestId(context.stringValue("RemovePrivilegesFromRoleResponse.RequestId"));<NEW_LINE>removePrivilegesFromRoleResponse... | ("RemovePrivilegesFromRoleResponse.Role.Privileges[" + i + "].PrivilegeName")); |
1,367,754 | public void paintInstance(InstancePainter painter) {<NEW_LINE>final var segmentWidth = 10;<NEW_LINE>var state = (State) painter.getData();<NEW_LINE>if (state == null || state.size != painter.getAttributeValue(ATTR_SIZE).getWidth()) {<NEW_LINE>final var val = (state == null) ? 0 : state.Value;<NEW_LINE>state = new State... | var x = loc.getX(); |
226,971 | protected JSONObject buildJsonMessage(CrawlURI curi) {<NEW_LINE>JSONObject message = new JSONObject().put("url", curi.toString());<NEW_LINE>if (getClientId() != null) {<NEW_LINE>message.put("clientId", getClientId());<NEW_LINE>}<NEW_LINE>if (getExtraInfo() != null) {<NEW_LINE>for (String k : getExtraInfo().keySet()) {<... | HashMap<String, Object>(); |
841,776 | private boolean foundAllFromHistoryAndTrimResults(SortedMap<T, Boolean> returnedMap, Integer currentStartIndex, Integer lastRelevantHistoryItemIndex, Integer limitStart, Integer limitCount, int numFromHistory) {<NEW_LINE>boolean foundAllFromHistory = false;<NEW_LINE>List<T> toRemove = new ArrayList<>();<NEW_LINE>if (nu... | >(returnedMap.keySet()); |
423,626 | /* Build call for applicationsApplicationIdPut */<NEW_LINE>private com.squareup.okhttp.Call applicationsApplicationIdPutCall(String applicationId, Application body, String contentType, String ifMatch, String ifUnmodifiedSince, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.Progr... | , progressListener)).build(); |
605,852 | // End of method isNeedleSafe<NEW_LINE>private void printPositions() {<NEW_LINE>int column = 1;<NEW_LINE>// Loop iterator<NEW_LINE>int ii = 0;<NEW_LINE>int numSpaces = 0;<NEW_LINE>int row = 1;<NEW_LINE>// Begin loop through all rows<NEW_LINE>for (row = 1; row <= MAX_NUM_ROWS; row++) {<NEW_LINE>numSpaces = 9;<NEW_LINE>/... | System.out.println(""); |
1,128,209 | public void onBackPressed() {<NEW_LINE>if (getCurrentMenu().close(true)) {<NEW_LINE>mFadeView.fadeOut();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (!getMainMenuController().isClosed()) {<NEW_LINE>getMainMenuController().close();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (mSearchController.closeBottomMenu())<NEW_LINE>return... | .get().getLastRouterType(); |
672,096 | private void sendJMSMessage(String host, int port, String msg, String protocol, String topicName, String clientID, String userName, String password, int timeToLive, boolean isDeliveryModePersistent) throws JMSException {<NEW_LINE>// Create a ConnectionFactory<NEW_LINE>// network protocol (tcp, ...) set as EXP_Processor... | createSession(true, Session.AUTO_ACKNOWLEDGE); |
1,150,606 | public void start() {<NEW_LINE>String brokerstatsZkurl = doctorKConf.getBrokerstatsZkurl();<NEW_LINE>String actionReportZkurl = doctorKConf.getActionReportZkurl();<NEW_LINE>String statsTopic = doctorKConf.getBrokerStatsTopic();<NEW_LINE>SecurityProtocol statsSecurityProtocol = doctorKConf.getBrokerStatsConsumerSecurity... | doctorKConf.getBrokerStatsConsumerSslConfigs(), replicaStatsManager); |
1,671,970 | public void run(@NotNull ProgressIndicator indicator) {<NEW_LINE>String currentFileName = null;<NEW_LINE>final long startTime = System.currentTimeMillis();<NEW_LINE>try {<NEW_LINE>for (int i = 0; i < fileDownloaders.size(); i++) {<NEW_LINE>final FileDownloader downloader = fileDownloaders.get(i);<NEW_LINE>assert downlo... | = System.currentTimeMillis() - startTime; |
243,931 | public void onCompletion(Message msg) {<NEW_LINE>Util.TRACE_ENTRY();<NEW_LINE>checkPause();<NEW_LINE>try {<NEW_LINE>exceptionOnUnrelatedClose_ = false;<NEW_LINE>unrelatedSession_.close();<NEW_LINE>} catch (JMSException e) {<NEW_LINE>Util.TRACE("unrelated session close() raised exception:" + e.getClass().getName() + " "... | " " + e.getMessage()); |
768,841 | private DownloadTask parseCursor(Cursor cursor) {<NEW_LINE>int primaryId = cursor.getInt(cursor.getColumnIndexOrThrow(BaseColumns._ID));<NEW_LINE>String taskId = cursor.getString(cursor.getColumnIndexOrThrow(TaskContract.TaskEntry.COLUMN_NAME_TASK_ID));<NEW_LINE>int status = cursor.getInt(cursor.getColumnIndexOrThrow(T... | (TaskContract.TaskEntry.COLUMN_NAME_RESUMABLE)); |
151,496 | public void bind(@NonNull IntroducingPayments model) {<NEW_LINE>if (model.isActivating()) {<NEW_LINE>activateButton.setVisibility(View.INVISIBLE);<NEW_LINE><MASK><NEW_LINE>} else {<NEW_LINE>activateButton.setVisibility(View.VISIBLE);<NEW_LINE>activatingGroup.setVisibility(View.GONE);<NEW_LINE>}<NEW_LINE>learnMoreView.s... | activatingGroup.setVisibility(View.VISIBLE); |
638,443 | private JComponent createColorButtonsPanel(final FileColorConfiguration configuration) {<NEW_LINE>final JPanel result = new JPanel(new BorderLayout());<NEW_LINE>result.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));<NEW_LINE>final JPanel inner = new JPanel();<NEW_LINE>inner.setLayout(new BoxLayout(inner, BoxLay... | get(configuration.getColorName()); |
1,367,288 | public String createNewAccount() {<NEW_LINE>AuthenticatedUserDisplayInfo newAud = new AuthenticatedUserDisplayInfo(newUser.getDisplayInfo().getFirstName(), newUser.getDisplayInfo().getLastName(), getSelectedEmail(), newUser.getDisplayInfo().getAffiliation(), newUser.getDisplayInfo().getPosition());<NEW_LINE>final Authe... | setOauthProviderId(newUser.getServiceId()); |
1,464,171 | // End of variables declaration//GEN-END:variables<NEW_LINE>@NbBundle.Messages({ "# {0} - filename", "ConfigVisualPanel1.configFileIsEmpty=Configuration file {0} is empty" })<NEW_LINE>private LogicalImagerConfig loadConfigFile(String path) throws FileNotFoundException, JsonIOException, JsonSyntaxException, IOException ... | (Bundle.ConfigVisualPanel1_configFileIsEmpty(path)); |
1,006,856 | public void onRender(MatrixStack matrixStack, float partialTicks) {<NEW_LINE>if (target == null)<NEW_LINE>return;<NEW_LINE>// GL settings<NEW_LINE>GL11.glEnable(GL11.GL_BLEND);<NEW_LINE>GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);<NEW_LINE>GL11.glEnable(GL11.GL_LINE_SMOOTH);<NEW_LINE><MASK><NEW_LIN... | GL11.glDisable(GL11.GL_DEPTH_TEST); |
1,769,867 | public void render(TileTank tile, double x, double y, double z, float partialTicks, int destroyStage, float alpha) {<NEW_LINE>FluidStackInterp forRender = tile.getFluidForRender(partialTicks);<NEW_LINE>if (forRender == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Minecraft.getMinecraft().mcProfiler.startSection("bc");<... | Vec3d max = connectedUp ? MAX_CONNECTED : MAX; |
749,020 | private Map<String, ShapeModel> constructExceptionShapes() {<NEW_LINE>// Java shape models, to be constructed<NEW_LINE>final Map<String, ShapeModel> javaShapes = new HashMap<String, ShapeModel>();<NEW_LINE>for (Map.Entry<String, Operation> entry : getServiceModel().getOperations().entrySet()) {<NEW_LINE>Operation opera... | ShapeType.Exception.getValue()); |
1,282,601 | public void adjustListViewForTv(@NonNull AppHolder viewHolder, @NonNull MainActivity mainActivity) {<NEW_LINE>try {<NEW_LINE>int[] location = new int[2];<NEW_LINE>viewHolder.rl.getLocationOnScreen(location);<NEW_LINE>Log.i(getClass().getSimpleName(), "Current x and y " + location[0] + " " + location[1]);<NEW_LINE>if (l... | getSimpleName(), "Failed to adjust scrollview for tv", e); |
1,378,921 | private void handleScriptField(MethodField method) throws SqlParseException {<NEW_LINE>List<KVValue<MASK><NEW_LINE>if (params.size() == 2) {<NEW_LINE>String f = params.get(0).value.toString();<NEW_LINE>fieldNames.add(f);<NEW_LINE>request.addScriptField(f, new Script(params.get(1).value.toString()));<NEW_LINE>} else if ... | > params = method.getParams(); |
1,280,146 | final ListTagsForResourceResult executeListTagsForResource(ListTagsForResourceRequest listTagsForResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listTagsForResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | false), new ListTagsForResourceResultJsonUnmarshaller()); |
1,705,395 | public Request<DisassociateChannelFlowRequest> marshall(DisassociateChannelFlowRequest disassociateChannelFlowRequest) {<NEW_LINE>if (disassociateChannelFlowRequest == null) {<NEW_LINE>throw new AmazonClientException("Invalid argument passed to marshall(DisassociateChannelFlowRequest)");<NEW_LINE>}<NEW_LINE>Request<Dis... | request.addHeader("Content-Type", "application/x-amz-json-1.0"); |
1,338,776 | private void dispatchInstanceTask(Service service, boolean ephemeral) {<NEW_LINE>ServiceStorage serviceStorage = ApplicationUtils.getBean(ServiceStorage.class);<NEW_LINE>InstanceUpgradeHelper instanceUpgradeHelper = ApplicationUtils.getBean(InstanceUpgradeHelper.class);<NEW_LINE>ServiceInfo serviceInfo = serviceStorage... | newInstance = service.allIPs(ephemeral); |
668,747 | public SubjectAreaOMASAPIResponse<HasA> restoreTermHasARelationship(String serverName, String userId, String guid) {<NEW_LINE>String restAPIName = "restoreTermHasARelationship";<NEW_LINE>RESTCallToken token = restCallLogger.logRESTCall(serverName, userId, restAPIName);<NEW_LINE>SubjectAreaOMASAPIResponse<HasA> <MASK><N... | response = new SubjectAreaOMASAPIResponse<>(); |
1,251,211 | public void init(InitParameters params) {<NEW_LINE>services = new EnumMap<>(CompactionKind.class);<NEW_LINE>var defaultService = CompactionDispatch.builder().toService("default").build();<NEW_LINE>if (params.getOptions().containsKey("service")) {<NEW_LINE>defaultService = CompactionDispatch.builder().toService(params.g... | (service).build()); |
94,046 | public void remove(Iterable<? extends Statement> statements, Resource... contexts) throws StoreException {<NEW_LINE>verifyContextNotNull(contexts);<NEW_LINE>verifyIsOpen();<NEW_LINE>verifyNotReadOnly();<NEW_LINE>if (repository.isReadOnly()) {<NEW_LINE>throw new StoreException("Repository is ReadOnly");<NEW_LINE>}<NEW_L... | (), _contexts[i]); |
386,507 | public static void horizontal(GrayU16 src, GrayF32 dst) {<NEW_LINE>if (src.width < dst.width)<NEW_LINE>throw new IllegalArgumentException("src width must be >= dst width");<NEW_LINE>if (src.height != dst.height)<NEW_LINE>throw new IllegalArgumentException("src height must equal dst height");<NEW_LINE>float scale = src.... | int x = dst.width - 1; |
1,732,138 | private static String copyJniLibraryFromClasspath() {<NEW_LINE>String name = System.mapLibraryName(LIB_NAME);<NEW_LINE>Path nativeDir = Utils.getEngineCacheDir("sentencepiece");<NEW_LINE>Platform platform = Platform.detectPlatform("sentencepiece");<NEW_LINE>String classifier = platform.getClassifier();<NEW_LINE>String ... | .toAbsolutePath().toString(); |
1,099,098 | public void createTupleType(MethodVisitor mv, BTupleType tupleType) {<NEW_LINE>mv.visitTypeInsn(NEW, TUPLE_TYPE_IMPL);<NEW_LINE>mv.visitInsn(DUP);<NEW_LINE>// Load type name<NEW_LINE>BTypeSymbol typeSymbol = tupleType.tsymbol;<NEW_LINE>if (typeSymbol == null) {<NEW_LINE>mv.visitLdcInsn(decodeIdentifier(tupleType.name.g... | jvmTypeGen.loadCyclicFlag(mv, tupleType); |
340,993 | public CompletableFuture<ReadHandle> readOffloaded(long ledgerId, MLDataFormats.OffloadContext ledgerContext, Map<String, String> offloadDriverMetadata) {<NEW_LINE>BlobStoreLocation bsKey = getBlobStoreLocation(offloadDriverMetadata);<NEW_LINE>String readBucket = bsKey.getBucket();<NEW_LINE>BlobStore readBlobstore = bl... | ), seg.getUidLsb()); |
257,432 | private void createHeader(Composite container) {<NEW_LINE>Composite composite = new Composite(container, SWT.NONE);<NEW_LINE>composite.setBackground(container.getBackground());<NEW_LINE>composite.setLayout(new FormLayout());<NEW_LINE>// logo<NEW_LINE>Label image = new Label(composite, SWT.NONE);<NEW_LINE>image.setBackg... | Label(composite, SWT.NONE); |
376,842 | void moveAddressRange(Address fromAddr, Address toAddr, long length, TaskMonitor monitor) throws AddressOverflowException, CancelledException {<NEW_LINE>lock.acquire();<NEW_LINE>try {<NEW_LINE>Address rangeEnd = fromAddr.addNoWrap(length - 1);<NEW_LINE>AddressSet addrSet = new AddressSet(fromAddr, rangeEnd);<NEW_LINE>A... | addrSet = addrSet.subtract(intersection); |
103,950 | private void zkInit() throws Exception {<NEW_LINE>//<NEW_LINE>centerPanel.appendChild(centerLayout);<NEW_LINE>//<NEW_LINE>bPrint.addActionListener(this);<NEW_LINE>bExport.addActionListener(this);<NEW_LINE>bCancel.addActionListener(this);<NEW_LINE>//<NEW_LINE>bProcess.setEnabled(false);<NEW_LINE>bProcess.addActionListen... | appendChild(paySelectSearch.getComponent()); |
1,761,826 | private void generateBuildScripts(Project project) {<NEW_LINE>try {<NEW_LINE>CordovaProjectExtender.createMobileConfigs(project.getProjectDirectory());<NEW_LINE>Preferences preferences = ProjectUtils.getPreferences(project, CordovaPlatform.class, true);<NEW_LINE>int version = preferences.getInt(PROP_BUILD_SCRIPT_VERSIO... | project, NAME_BUILD_XML, PATH_BUILD_XML, true); |
965,713 | public static CodegenExpression codegenGetterEventDistinct(boolean isDistinct, EventType eventType, MultiKeyClassRef optionalDistinctMultiKey, CodegenMethod method, CodegenClassScope classScope) {<NEW_LINE>if (!isDistinct) {<NEW_LINE>return constantNull();<NEW_LINE>}<NEW_LINE>String[] propertyNames = eventType.getPrope... | = new EPType[propertyNames.length]; |
293,197 | public void completed(ClientExchange result) {<NEW_LINE>new StringWriteChannelListener(requestBody).setup(result.getRequestChannel());<NEW_LINE>result.setResponseListener(new ClientCallback<ClientExchange>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void completed(ClientExchange result) {<NEW_LINE>new StringReadCh... | complete(result.getResponse()); |
525,623 | public final <K> Map<K, ?> toMap(K key1, K key2, K key3, K key4, K key5, K key6, K key7, K key8, K key9, K key10, K key11, K key12, K key13, K key14, K key15, K key16) {<NEW_LINE>Map<K, Object> result = new LinkedHashMap<>();<NEW_LINE>result.put(key1, v1);<NEW_LINE>result.put(key2, v2);<NEW_LINE>result.put(key3, v3);<N... | result.put(key13, v13); |
1,789,287 | private JibContainerBuilder createContainerBuilderFromNative(JibConfig jibConfig, ContainerImageConfig containerImageConfig, NativeImageBuildItem nativeImageBuildItem, List<ContainerImageLabelBuildItem> containerImageLabels) {<NEW_LINE>List<String> entrypoint;<NEW_LINE>if (jibConfig.nativeEntrypoint.isPresent()) {<NEW_... | workDirInContainer = AbsoluteUnixPath.get("/work"); |
1,269,641 | // General classes<NEW_LINE>@Override<NEW_LINE>public void visitJavaClass(JavaClass obj) {<NEW_LINE>setupVisitorForClass(obj);<NEW_LINE>if (shouldVisit(obj)) {<NEW_LINE>constantPool.accept(this);<NEW_LINE>Field[] fields = obj.getFields();<NEW_LINE>Attribute[] attributes = obj.getAttributes();<NEW_LINE>for (Field field ... | c = DescriptorFactory.createClassDescriptor(obj); |
1,818,816 | public com.amazonaws.services.ecs.model.ServiceNotFoundException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.ecs.model.ServiceNotFoundException serviceNotFoundException = new com.amazonaws.services.ecs.model.ServiceNotFoundException(null);<NEW_LINE>int origi... | String currentParentElement = context.getCurrentParentElement(); |
284,123 | public static ListAlarmHistoriesResponse unmarshall(ListAlarmHistoriesResponse listAlarmHistoriesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listAlarmHistoriesResponse.setRequestId<MASK><NEW_LINE>listAlarmHistoriesResponse.setNextToken(_ctx.stringValue("ListAlarmHistoriesResponse.NextToken"));<NEW_LINE>listAlarmHist... | (_ctx.stringValue("ListAlarmHistoriesResponse.RequestId")); |
466,618 | public void draw(Batch batch, float x, float y, float width, float height) {<NEW_LINE>float oldColor = batch.getPackedColor();<NEW_LINE>batch.setColor(batch.getColor().mul(color));<NEW_LINE>TextureRegion region = getRegion();<NEW_LINE>float regionWidth = region.getRegionWidth() * scale, regionHeight = region.getRegionH... | u, v2, u2, v); |
1,568,280 | final GetQueryExecutionResult executeGetQueryExecution(GetQueryExecutionRequest getQueryExecutionRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getQueryExecutionRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_LINE>Request<GetQueryExecutionReq... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
668,782 | final DeleteStreamingDistributionResult executeDeleteStreamingDistribution(DeleteStreamingDistributionRequest deleteStreamingDistributionRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteStreamingDistributionRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.get... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "DeleteStreamingDistribution"); |
423,663 | public static String[] annotateTypeParameter(String originalSignature, String annotatedType, int rank, MergeStrategy mergeStrategy) {<NEW_LINE>// prefix, orig, replacement, postfix<NEW_LINE>String[] result = new String[4];<NEW_LINE>StringBuffer buf = new StringBuffer();<NEW_LINE>// may already contain annotations<NEW_L... | toCharArray(), true, true); |
46,162 | private static double findMedoid(DistanceQuery<?> dq, DBIDs c, DBIDArrayMIter prototype) {<NEW_LINE>if (c.size() == 2) {<NEW_LINE>final <MASK><NEW_LINE>prototype.setDBID(other);<NEW_LINE>return dq.distance(prototype, other.advance());<NEW_LINE>}<NEW_LINE>double minDistSum = Double.POSITIVE_INFINITY;<NEW_LINE>for (DBIDI... | DBIDIter other = c.iter(); |
1,075,235 | public static X509Certificate newCertificateAuthority(X509Metadata metadata, File storeFile, X509Log x509log) {<NEW_LINE>try {<NEW_LINE>KeyPair caPair = newKeyPair();<NEW_LINE>ContentSigner caSigner = new JcaContentSignerBuilder(SIGNING_ALGORITHM).setProvider(BC).build(caPair.getPrivate());<NEW_LINE>// clone metadata<N... | .keyCertSign | KeyUsage.cRLSign)); |
132,421 | public Tuple2<Double, Double> calcHessianGradientLoss(Iterable<Tuple3<Double, Double, Vector>> labelVectors, DenseVector coefVector, DenseMatrix hessian, DenseVector grad) {<NEW_LINE>if (this.hasSecondDerivative()) {<NEW_LINE>int size = grad.size();<NEW_LINE>for (int i = 0; i < size; ++i) {<NEW_LINE>grad.set(i, 0.0);<N... | Tuple2.of(weightSum, loss); |
390,748 | public void updateBlock(GlowBlock block) {<NEW_LINE>MaterialData data = block.getState().getData();<NEW_LINE>if (data instanceof CocoaPlant) {<NEW_LINE>CocoaPlant cocoa = (CocoaPlant) data;<NEW_LINE><MASK><NEW_LINE>if (size != CocoaPlantSize.LARGE && ThreadLocalRandom.current().nextInt(5) == 0) {<NEW_LINE>if (size == C... | CocoaPlantSize size = cocoa.getSize(); |
1,842,842 | public static Set<String> wildcardMatch(String queryStr, Collection<String> commands, boolean includeCaseInsensitiveStartingWith) {<NEW_LINE>Set<String> matches = Sets.newHashSet();<NEW_LINE>String query = queryStr.replaceAll("\\*", ".*?");<NEW_LINE>query = query.replaceAll("\\(|\\)|\\[|\\]|\\{|\\}", "");<NEW_LINE>quer... | m = regex.matcher(cmd); |
1,692,580 | public void updateProfile(String appName, ReadableMap props, final Promise promise) {<NEW_LINE>FirebaseApp firebaseApp = FirebaseApp.getInstance(appName);<NEW_LINE>final FirebaseAuth firebaseAuth = FirebaseAuth.getInstance(firebaseApp);<NEW_LINE>FirebaseUser user = firebaseAuth.getCurrentUser();<NEW_LINE><MASK><NEW_LIN... | Log.d(TAG, "updateProfile"); |
1,032,751 | public void actionPerformed(ActionEvent e) {<NEW_LINE>log.fine("Event:" + e.getSource());<NEW_LINE>panel.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));<NEW_LINE>if (e.getActionCommand().equals(ConfirmPanel.A_CANCEL)) {<NEW_LINE>dispose();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (e.getSource().equals(Process... | ), "Info", JOptionPane.INFORMATION_MESSAGE); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.