instruction
string
input
string
output
string
source_file
string
priority
int64
请完成以下Java代码
public void setQM_QtyDeliveredAvg(final BigDecimal qtyDeliveredAvg) { ppOrder.setQM_QtyDeliveredAvg(qtyDeliveredAvg); } @Override public BigDecimal getQM_QtyDeliveredAvg() { return ppOrder.getQM_QtyDeliveredAvg(); } @Override public Object getModel() { return ppOrder; } @Override public String getV...
{ if (!_handlingUnitsInfoLoaded) { _handlingUnitsInfo = handlingUnitsInfoFactory.createFromModel(ppOrder); _handlingUnitsInfoLoaded = true; } return _handlingUnitsInfo; } @Override public I_M_Product getMainComponentProduct() { // there is no substitute for a produced material return null; } }
repos\metasfresh-new_dawn_uat\backend\de.metas.materialtracking\src\main\java\de\metas\materialtracking\qualityBasedInvoicing\impl\PPOrderProductionMaterial.java
1
请完成以下Java代码
public void setPageContext(PageContext pageContext) { this.pageContext = pageContext; } @Override protected ServletRequest getRequest() { return this.pageContext.getRequest(); } @Override protected ServletResponse getResponse() { return this.pageContext.getResponse(); } @Override protected ServletCont...
public TypeComparator getTypeComparator() { return this.delegate.getTypeComparator(); } @Override public OperatorOverloader getOperatorOverloader() { return this.delegate.getOperatorOverloader(); } @Override public @Nullable BeanResolver getBeanResolver() { return this.delegate.getBeanResolver();...
repos\spring-security-main\taglibs\src\main\java\org\springframework\security\taglibs\authz\JspAuthorizeTag.java
1
请完成以下Java代码
public Long getId() { return id; } public void setId(Long id) { this.id = id; } public Long getAmount() { return amount; } public void setAmount(Long amount) { this.amount = amount; } public String getReferenceNumber() { return referenceNumber;...
public void setReferenceNumber(String referenceNumber) { this.referenceNumber = referenceNumber; } public State getState() { return state; } public void setState(State state) { this.state = state; } public enum State { STARTED, FAILED, SUCCESSFUL } }
repos\tutorials-master\persistence-modules\spring-data-jpa-annotations\src\main\java\com\baeldung\tx\model\Payment.java
1
请完成以下Java代码
public void detectDataSourceDefinition(@Observes @WithAnnotations(DataSourceDefinition.class) ProcessAnnotatedType<?> patEvent) { AnnotatedType at = patEvent.getAnnotatedType(); dataSourceDefinition = at.getAnnotation(DataSourceDefinition.class); } public void processAnnotatedType(@Observes Pro...
.scope(ApplicationScoped.class) .name(DataSource.class.getName()) .beanClass(DataSource.class) .createWith(creationalContext -> { DataSource instance = new DataSource(); instance.setUrl(dataSourceDefinition.url()); ...
repos\tutorials-master\di-modules\flyway-cdi-extension\src\main\java\com\baeldung\cdi\extension\FlywayExtension.java
1
请完成以下Java代码
public void removeAtIndex(int index) { if (index < 0 || index >= size) { throw new IndexOutOfBoundsException("Index out of bounds"); } if (index == 0) { removeHead(); return; } Node<T> current = head; for (int i = 0; i < index - 1; i+...
public int size() { return size; } @Override public String toString() { StringBuilder builder = new StringBuilder(); Node<T> temp = head; while (temp != null) { builder.append(temp.value) .append("->"); if (temp == tail) ...
repos\tutorials-master\core-java-modules\core-java-collections-7\src\main\java\com\baeldung\customlinkedlist\CustomLinkedList.java
1
请完成以下Java代码
public BigDecimal getRealAmount() { return realAmount; } public void setRealAmount(BigDecimal realAmount) { this.realAmount = realAmount; } public Integer getGiftIntegration() { return giftIntegration; } public void setGiftIntegration(Integer giftIntegration) { ...
sb.append(", productId=").append(productId); sb.append(", productPic=").append(productPic); sb.append(", productName=").append(productName); sb.append(", productBrand=").append(productBrand); sb.append(", productSn=").append(productSn); sb.append(", productPrice=").append(product...
repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\OmsOrderItem.java
1
请完成以下Java代码
public List<MSV3User> getAllUsers() { return usersRepo.findAll() .stream() .map(jpaUser -> toMSV3User(jpaUser)) .collect(ImmutableList.toImmutableList()); } @Transactional public void handleEvent(@NonNull final MSV3UserChangedBatchEvent batchEvent) { final String mfSyncToken = batchEvent.getId(); ...
final String username = event.getUsername(); JpaUser user = usersRepo.findByMfMSV3UserId(event.getMsv3MetasfreshUserId().getId()); if (user == null) { user = new JpaUser(); user.setMfMSV3UserId(event.getMsv3MetasfreshUserId().getId()); } user.setMfUsername(username); user.setMfPassword(event...
repos\metasfresh-new_dawn_uat\backend\de.metas.vertical.pharma.msv3.server\src\main\java\de\metas\vertical\pharma\msv3\server\security\MSV3ServerAuthenticationService.java
1
请完成以下Java代码
public int getFailedJobs() { return failedJobs; } public void setFailedJobs(int failedJobs) { this.failedJobs = failedJobs; } public int getJobsToCreate() { return totalJobs - jobsCreated; } public String toString() { return "BatchStatisticsEntity{" + "batchHandler=" + batchJobHandl...
", type='" + type + '\'' + ", size=" + totalJobs + ", jobCreated=" + jobsCreated + ", remainingJobs=" + remainingJobs + ", failedJobs=" + failedJobs + ", batchJobsPerSeed=" + batchJobsPerSeed + ", invocationsPerBatchJob=" + invocationsPerBatchJob + ", seedJobDefinitionId='" + s...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\batch\BatchStatisticsEntity.java
1
请完成以下Spring Boot application配置
spring: application: name: demo-consumer-application cloud: # Spring Cloud Stream 配置项,对应 BindingServiceProperties 类 stream: # Binder 配置项,对应 BinderProperties Map # binders: # Binding 配置项,对应 BindingProperties Map bindings: demo01-input: destination: DEMO-TOPIC-01 #...
oints: web: exposure: include: '*' # 需要开放的端点。默认值只打开 health 和 info 两个端点。通过设置 * ,可以开放所有端点。 endpoint: # Health 端点配置项,对应 HealthProperties 配置类 health: enabled: true # 是否开启。默认为 true 开启。 show-details: ALWAYS # 何时显示完整的健康信息。默认为 NEVER 都不展示。可选 WHEN_AUTHORIZED 当经过授权的用户;可选 ALWAYS 总是展示。
repos\SpringBoot-Labs-master\labx-11-spring-cloud-stream-kafka\labx-11-sc-stream-kafka-consumer-actuator\src\main\resources\application.yml
2
请完成以下Java代码
protected int resolveRetries(HistoryCleanupContext context) { return context.getMaxRetries(); } @Override public Date resolveDueDate(HistoryCleanupContext context) { return resolveDueDate(context.isImmediatelyDue()); } private Date resolveDueDate(boolean isImmediatelyDue) { CommandContext comman...
if (currentOrNextBatchWindow != null) { return currentOrNextBatchWindow.getStart(); } else { return null; } } } public ParameterValueProvider getJobPriorityProvider() { ProcessEngineConfigurationImpl configuration = Context.getProcessEngineConfiguration(); long historyCleanu...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\jobexecutor\historycleanup\HistoryCleanupJobDeclaration.java
1
请在Spring Boot框架中完成以下Java代码
public String getImageUrl() { return imageUrl; } public void setImageUrl(String imageUrl) { this.imageUrl = imageUrl; } public boolean isActivated() { return activated; } public void setActivated(boolean activated) { this.activated = activated; } publi...
public Set<Authority> getAuthorities() { return authorities; } public void setAuthorities(Set<Authority> authorities) { this.authorities = authorities; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instance...
repos\tutorials-master\jhipster-8-modules\jhipster-8-microservice\gateway-app\src\main\java\com\gateway\domain\User.java
2
请完成以下Java代码
public static void stringFormat() { List<BodyMassIndex> bodyMassIndices = new ArrayList<>(); bodyMassIndices.add(new BodyMassIndex("Tom", 1.8, 80)); bodyMassIndices.add(new BodyMassIndex("Elton", 1.9, 90)); bodyMassIndices.add(new BodyMassIndex("Harry", 1.9, 90)); bodyMassIndices...
bodyMassIndices.add(new BodyMassIndex("Hannah", 1.9, 90)); AsciiTable asciiTable = new AsciiTable(); asciiTable.addRule(); asciiTable.addRow("Name", "Height", "Weight", "BMI"); asciiTable.addRule(); for (BodyMassIndex bodyMassIndex : bodyMassIndices) { asciiTable.a...
repos\tutorials-master\core-java-modules\core-java-console\src\main\java\com\baeldung\consoletableoutput\BodyMassIndexApplication.java
1
请完成以下Java代码
protected String doIt() throws Exception { final String whereClause = ""; final List<MBPartner> bPartners = new Query(getCtx(), I_C_BPartner.Table_Name, whereClause, get_TrxName()) .setOnlyActiveRecords(true).setClient_ID().list(MBPartner.class); final Timestamp startDate = SystemTime.asTimestamp(); ...
inputEditorKit.read(r, doc, 0); final HTMLEditorKit outputEditorKit = new HTMLEditorKit(); final ByteArrayOutputStream outpOutputStream = new ByteArrayOutputStream(); outputEditorKit.write(outpOutputStream, doc, 0, doc.getLength()); final String memoHtml = outpOutputStream.toString().replace( "font-...
repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\adempiere\process\ConvertBPartnerMemo.java
1
请完成以下Java代码
public class CredProtectAuthenticationExtensionsClientInput implements AuthenticationExtensionsClientInput<CredProtectAuthenticationExtensionsClientInput.CredProtect> { @Serial private static final long serialVersionUID = -6418175591005843455L; private final CredProtect input; public CredProtectAuthenticationE...
private final ProtectionPolicy credProtectionPolicy; private final boolean enforceCredentialProtectionPolicy; public CredProtect(ProtectionPolicy credProtectionPolicy, boolean enforceCredentialProtectionPolicy) { this.enforceCredentialProtectionPolicy = enforceCredentialProtectionPolicy; this.credProtection...
repos\spring-security-main\webauthn\src\main\java\org\springframework\security\web\webauthn\api\CredProtectAuthenticationExtensionsClientInput.java
1
请完成以下Java代码
protected String getPasswordToUse(final String hostname, final String port, final String dbName, final String user, final String password) throws SQLException { String passwordToUse = password; final Object configKey = mkKey(hostname, port, dbName, user); // // Password not available: check cached configurat...
if (IDatabase.PASSWORD_NA == passwordToUse) { throw new SQLException("No password was found for request: " + "hostname=" + hostname + ", port=" + port + ", dbName=" + dbName + ", user=" + user); } return passwordToUse; } private Object mkKey(final String hostname, final String port, fin...
repos\metasfresh-new_dawn_uat\backend\de.metas.migration\de.metas.migration.base\src\main\java\de\metas\migration\sql\postgresql\PgSQLDatabaseDriver.java
1
请完成以下Java代码
public void addElement (PrintElement element) { if (element != null) m_elements.add(element); m_pe = null; } // addElement /** * Get Elements * @return array of elements */ public PrintElement[] getElements() { if (m_pe == null) { m_pe = new PrintElement[m_elements.size()]; m_elements.toAr...
m_pe[i].paint(g2D, 0, pageStart, m_ctx, isView); } // paint /** * Get DrillDown value * @param relativePoint relative Point * @return if found NamePait or null */ public MQuery getDrillDown (Point relativePoint) { MQuery retValue = null; for (int i = 0; i < m_elements.size() && retValue == null; i++...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-legacy\org\compiere\print\layout\HeaderFooter.java
1
请完成以下Java代码
public boolean isSeriesOrder() { return get_ValueAsBoolean(COLUMNNAME_IsSeriesOrder); } @Override public void setNextDelivery (final @Nullable java.sql.Timestamp NextDelivery) { set_Value (COLUMNNAME_NextDelivery, NextDelivery); } @Override public java.sql.Timestamp getNextDelivery() { return get_Val...
@Override public void setStartDate (final @Nullable java.sql.Timestamp StartDate) { set_Value (COLUMNNAME_StartDate, StartDate); } @Override public java.sql.Timestamp getStartDate() { return get_ValueAsTimestamp(COLUMNNAME_StartDate); } @Override public void setTimePeriod (final @Nullable BigDecimal Tim...
repos\metasfresh-new_dawn_uat\backend\de.metas.vertical.healthcare.alberta\src\main\java-gen\de\metas\vertical\healthcare\alberta\model\X_C_OLCand_AlbertaOrder.java
1
请在Spring Boot框架中完成以下Java代码
public class UmsMemberCouponController { @Autowired private UmsMemberCouponService memberCouponService; @Autowired private OmsCartItemService cartItemService; @Autowired private UmsMemberService memberService; @ApiOperation("领取指定优惠券") @RequestMapping(value = "/add/{couponId}", method = ...
allowableValues = "0,1,2", paramType = "query", dataType = "integer") @RequestMapping(value = "/list", method = RequestMethod.GET) @ResponseBody public CommonResult<List<SmsCoupon>> list(@RequestParam(value = "useStatus", required = false) Integer useStatus) { List<SmsCoupon> couponList = memberCoup...
repos\mall-master\mall-portal\src\main\java\com\macro\mall\portal\controller\UmsMemberCouponController.java
2
请完成以下Java代码
public void existingLU(final HuId luId, final HUQRCode luQRCode) {consolidate_FromLUs_ToExistingLU(fromLUs, luId, luQRCode);} }); } @SuppressWarnings("unused") private void consolidate_FromLUs_ToNewLU(@NonNull final List<I_M_HU> fromLUs, @NonNull final HuPackingInstructionsId luPackingInstructionsId) { throw n...
} private void consolidate_FromTUs_ToNewLU(@NonNull final List<I_M_HU> fromTUs, @NonNull final HuPackingInstructionsId luPackingInstructionsId) { if (fromTUs.isEmpty()) { return; } final I_M_HU firstTU = fromTUs.get(0); final I_M_HU lu = huTransformService.tuToNewLU(firstTU, QtyTU.ONE, luPackingInstruc...
repos\metasfresh-new_dawn_uat\backend\de.metas.hu_consolidation.mobile\src\main\java\de\metas\hu_consolidation\mobile\job\commands\consolidate\ConsolidateCommand.java
1
请完成以下Java代码
private void clearGroups() { for (final FavoritesGroup group : topNodeId2group.values()) { group.removeAllItems(); } topNodeId2group.clear(); panel.removeAll(); } public boolean isEmpty() { return topNodeId2group.isEmpty(); } private final void updateUI() { final JComponent comp = getComponen...
final JComponent comp = getComponent(); if (!comp.isVisible()) { return; // nothing to update } // Find parent split pane if any JSplitPane parentSplitPane = null; for (Component c = comp.getParent(); c != null; c = c.getParent()) { if (c instanceof JSplitPane) { parentSplitPane = (JSplitPan...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java-legacy\org\compiere\grid\tree\FavoritesGroupContainer.java
1
请在Spring Boot框架中完成以下Java代码
void configure(HttpSecurity httpSecurity) { AuthenticationManager authenticationManager = httpSecurity.getSharedObject(AuthenticationManager.class); AuthorizationServerSettings authorizationServerSettings = OAuth2ConfigurerUtils .getAuthorizationServerSettings(httpSecurity); String pushedAuthorizationRequestEn...
RequestMatcher getRequestMatcher() { return this.requestMatcher; } private static List<AuthenticationConverter> createDefaultAuthenticationConverters() { List<AuthenticationConverter> authenticationConverters = new ArrayList<>(); authenticationConverters.add(new OAuth2AuthorizationCodeRequestAuthenticationCon...
repos\spring-security-main\config\src\main\java\org\springframework\security\config\annotation\web\configurers\oauth2\server\authorization\OAuth2PushedAuthorizationRequestEndpointConfigurer.java
2
请完成以下Java代码
public void enableStepRequest(VirtualMachine vm, BreakpointEvent event) { //enable step request for last break point if(event.location().toString().contains(debugClass.getName()+":"+breakPointLines[breakPointLines.length-1])) { StepRequest stepRequest = vm.eventRequestManager().createStepReq...
} } } catch (VMDisconnectedException e) { System.out.println("Virtual Machine is disconnected."); } catch (Exception e) { e.printStackTrace(); } finally { InputStreamReader reader = new InputStreamReader(vm.process().getInputStream()); ...
repos\tutorials-master\java-jdi\src\main\java\com\baeldung\jdi\JDIExampleDebugger.java
1
请完成以下Java代码
public boolean isEnabled() { return enabled; } public void setEnabled(boolean enabled) { this.enabled = enabled; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } RouteDefinition that = (RouteDefinition...
&& Objects.equals(this.uri, that.uri) && Objects.equals(this.metadata, that.metadata) && Objects.equals(this.enabled, that.enabled); } @Override public int hashCode() { return Objects.hash(this.id, this.predicates, this.filters, this.uri, this.metadata, this.order, this.enabled); } @Override public String...
repos\spring-cloud-gateway-main\spring-cloud-gateway-server-webflux\src\main\java\org\springframework\cloud\gateway\route\RouteDefinition.java
1
请完成以下Java代码
public AttachmentEntityManager getAttachmentEntityManager() { return getSession(AttachmentEntityManager.class); } public TableDataManager getTableDataManager() { return getSession(TableDataManager.class); } public CommentEntityManager getCommentEntityManager() { return getSessi...
} public Throwable getException() { return exception; } public FailedJobCommandFactory getFailedJobCommandFactory() { return failedJobCommandFactory; } public ProcessEngineConfigurationImpl getProcessEngineConfiguration() { return processEngineConfiguration; } pub...
repos\flowable-engine-main\modules\flowable5-engine\src\main\java\org\activiti\engine\impl\interceptor\CommandContext.java
1
请完成以下Java代码
public InterestType1Choice getTp() { return tp; } /** * Sets the value of the tp property. * * @param value * allowed object is * {@link InterestType1Choice } * */ public void setTp(InterestType1Choice value) { this.tp = value; } /**...
* @return * possible object is * {@link DateTimePeriodDetails } * */ public DateTimePeriodDetails getFrToDt() { return frToDt; } /** * Sets the value of the frToDt property. * * @param value * allowed object is * {@link DateTimePeri...
repos\metasfresh-new_dawn_uat\backend\de.metas.banking\de.metas.banking.camt53\src\main\java-xjc\de\metas\banking\camt53\jaxb\camt053_001_02\AccountInterest2.java
1
请完成以下Java代码
public void setHasStartFormKey(boolean hasStartFormKey) { this.hasStartFormKey = hasStartFormKey; } public boolean isGraphicalNotationDefined() { return isGraphicalNotationDefined; } @Override public boolean hasGraphicalNotation() { return isGraphicalNotationDefined; } ...
public void addCandidateStarterUserIdExpression(Expression userId) { candidateStarterUserIdExpressions.add(userId); } public Set<Expression> getCandidateStarterGroupIdExpressions() { return candidateStarterGroupIdExpressions; } public void addCandidateStarterGroupIdExpression(Expressio...
repos\flowable-engine-main\modules\flowable5-engine\src\main\java\org\activiti\engine\impl\persistence\entity\ProcessDefinitionEntity.java
1
请完成以下Java代码
public void setMsgText (java.lang.String MsgText) { set_ValueNoCheck (COLUMNNAME_MsgText, MsgText); } /** Get Message Text. @return Textual Informational, Menu or Error Message */ @Override public java.lang.String getMsgText () { return (java.lang.String)get_Value(COLUMNNAME_MsgText); } /** Set Sequ...
@Override public void setSeqNo (int SeqNo) { set_ValueNoCheck (COLUMNNAME_SeqNo, Integer.valueOf(SeqNo)); } /** Get Sequence. @return Method of ordering records; lowest number comes first */ @Override public int getSeqNo () { Integer ii = (Integer)get_Value(COLUMNNAME_SeqNo); if (ii == null) ret...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\de\metas\letters\model\X_T_BoilerPlate_Spool.java
1
请在Spring Boot框架中完成以下Java代码
public static class AdditionalSizeInformation { @XmlValue protected String content; @XmlAttribute(name = "Type", namespace = "http://erpel.at/schemas/1p0/documents/extensions/edifact") @XmlSchemaType(name = "anySimpleType") protected String type; /** * Gets the...
*/ public String getType() { return type; } /** * Sets the value of the type property. * * @param value * allowed object is * {@link String } * */ public void setType(String value) { thi...
repos\metasfresh-new_dawn_uat\misc\services\camel\de-metas-camel-edi\src\main\java-xjc_ecosio_remadv\at\erpel\schemas\_1p0\documents\extensions\edifact\SizeType.java
2
请完成以下Java代码
public static I_C_Flatrate_Term retrieveTerm(@NonNull final I_C_Invoice_Candidate ic) { return IC_2_TERM.getOrLoad(ic.getC_Invoice_Candidate_ID(), () -> retrieveTermForCache(ic)); } private static I_C_Flatrate_Term retrieveTermForCache(@NonNull final I_C_Invoice_Candidate ic) { final int flatrateTermTableId = ...
.billLocationAdapter(ic) .setFrom(ContractLocationHelper.extractBillLocation(term)); } public static UomId retrieveUomId(@NonNull final I_C_Invoice_Candidate icRecord) { final I_C_Flatrate_Term term = retrieveTerm(icRecord); if (term.getC_UOM_ID() > 0) { return UomId.ofRepoId(term.getC_UOM_ID()); } ...
repos\metasfresh-new_dawn_uat\backend\de.metas.contracts\src\main\java\de\metas\contracts\invoicecandidate\HandlerTools.java
1
请在Spring Boot框架中完成以下Java代码
public class DatabaseProperties { public static class Server { /** * The IP of the database server */ private String ip; /** * The Port of the database server. * The Default value is 443. * The allowed values are in the range 400-4000. ...
} } private String username; private String password; private Server server; public String getUsername() { return username; } public void setUsername(String username) { this.username = username; } public String getPassword() { return password; } p...
repos\tutorials-master\spring-boot-modules\spring-boot-autoconfiguration\src\main\java\com\baeldung\autoconfiguration\annotationprocessor\DatabaseProperties.java
2
请在Spring Boot框架中完成以下Java代码
public class StorageConfiguration { private final StorageProperties storageProperties; public StorageConfiguration(StorageProperties storageProperties) { this.storageProperties = storageProperties; } @Bean @Profile("azure") public BlobStore azureBlobStore() { return ContextBui...
public S3Client s3Client() { S3Configuration s3Configuration = S3Configuration .builder() .checksumValidationEnabled(false) .build(); AwsCredentials credentials = AwsBasicCredentials.create( storageProperties.getIdentity(), storageProperties.ge...
repos\tutorials-master\aws-modules\s3proxy\src\main\java\com\baeldung\s3proxy\StorageConfiguration.java
2
请完成以下Java代码
public int getM_FreightCategory_ID () { Integer ii = (Integer)get_Value(COLUMNNAME_M_FreightCategory_ID); if (ii == null) return 0; return ii.intValue(); } /** Set Name. @param Name Alphanumeric identifier of the entity */ public void setName (String Name) { set_Value (COLUMNNAME_Name, Name);...
{ return new KeyNamePair(get_ID(), getName()); } /** Set Search Key. @param Value Search key for the record in the format required - must be unique */ public void setValue (String Value) { set_Value (COLUMNNAME_Value, Value); } /** Get Search Key. @return Search key for the record in the ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_M_FreightCategory.java
1
请完成以下Java代码
private void scan(BeanDefinitionRegistry registry, Set<String> packages) { ConfigurationPropertiesBeanRegistrar registrar = new ConfigurationPropertiesBeanRegistrar(registry); ClassPathScanningCandidateComponentProvider scanner = getScanner(registry); for (String basePackage : packages) { for (BeanDefinition c...
} private void register(ConfigurationPropertiesBeanRegistrar registrar, String className) throws LinkageError { try { register(registrar, ClassUtils.forName(className, null)); } catch (ClassNotFoundException ex) { // Ignore } } private void register(ConfigurationPropertiesBeanRegistrar registrar, Cla...
repos\spring-boot-4.0.1\core\spring-boot\src\main\java\org\springframework\boot\context\properties\ConfigurationPropertiesScanRegistrar.java
1
请完成以下Java代码
public IQueryFilter<T> createFilter(@NonNull final List<AttributesKeyPattern> attributesKeyPatterns) { Check.assumeNotEmpty(attributesKeyPatterns, "attributesKeyPatterns is not empty"); if (attributesKeyPatterns.contains(AttributesKeyPattern.ALL)) { return ConstantQueryFilter.of(true); } if (attributesK...
final StringLikeFilter<T> filter = new StringLikeFilter<>(modelColumn.getColumnName(), likeExpression, ignoreCase); filters.add(filter); } if (filters.isEmpty()) { return ConstantQueryFilter.of(true); } else if (filters.size() == 1) { return filters.get(0); } else { return queryBL.create...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\org\adempiere\mm\attributes\keys\AttributesKeyQueryHelper.java
1
请完成以下Java代码
public String toString() { return ObjectUtils.toString(this); } @Override public boolean equals(final Object obj) { if (this == obj) { return true; } final InvoiceLineAttribute other = EqualsBuilder.getOther(this, obj); if (other == null) { return false; } return new EqualsBuilder() ....
.append(aggregationKey) .toHashcode(); } @Override public String toAggregationKey() { return aggregationKey; } @Override public I_M_AttributeInstance getAttributeInstanceTemplate() { return attributeInstanceTemplate; } }
repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\invoicecandidate\api\impl\InvoiceLineAttribute.java
1
请完成以下Java代码
public String retrieveDBVersion( @NonNull final DBConnectionSettings settings, @NonNull final String dbName) { final IDatabase dbConnection = dbConnectionMaker.createDummyDatabase(settings, dbName); try (final Connection connection = dbConnection.getConnection(); final Statement stmt = connection.create...
// fail throw new CantRetrieveDBVersionException("Could not retrieve the DB version; selectSql=" + SELECT_DB_VERSION_SQL, e); } } private String retrieveDBVersion0(final Statement stmt) throws SQLException { final ResultSet resultSet = stmt.executeQuery(SELECT_DB_VERSION_SQL); resultSet.next(); final Str...
repos\metasfresh-new_dawn_uat\backend\de.metas.migration\de.metas.migration.cli\src\main\java\de\metas\migration\cli\rollout_migrate\DBVersionGetter.java
1
请在Spring Boot框架中完成以下Java代码
public boolean destroy() { try { if (consumer != null) { log.info("[{}][{}] Stopping edge event consumer...", tenantId, edge != null ? edge.getId() : null); consumer.stop(); } } catch (Exception e) { log.warn("[{}][{}] Failed to stop ed...
} return true; } private void awaitConsumerTermination() { try { consumerExecutor.awaitTermination(5, java.util.concurrent.TimeUnit.SECONDS); } catch (InterruptedException ie) { log.warn("[{}][{}] Interrupted while awaiting consumer executor termination", tenantI...
repos\thingsboard-master\application\src\main\java\org\thingsboard\server\service\edge\rpc\KafkaEdgeGrpcSession.java
2
请完成以下Java代码
protected org.compiere.model.POInfo initPO(final Properties ctx) { return org.compiere.model.POInfo.getPOInfo(Table_Name); } /** * FilterType AD_Reference_ID=541849 * Reference name: PickingFilter_Options */ public static final int FILTERTYPE_AD_Reference_ID=541849; /** Customer = Customer */ public sta...
{ if (PickingProfile_Filter_ID < 1) set_ValueNoCheck (COLUMNNAME_PickingProfile_Filter_ID, null); else set_ValueNoCheck (COLUMNNAME_PickingProfile_Filter_ID, PickingProfile_Filter_ID); } @Override public int getPickingProfile_Filter_ID() { return get_ValueAsInt(COLUMNNAME_PickingProfile_Filter_ID); ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\de\metas\picking\model\X_PickingProfile_Filter.java
1
请完成以下Spring Boot application配置
spring.datasource.url=jdbc:mysql://localhost:3306/world?useSSL=false&characterEncoding=UTF-8&serverTimezone=UTC spring.datasource.username=root spring.datasource.password=posilka2020 spring.datasource.driver-class-name=com.mysql.jdbc.Driver spring.jpa.database-p
latform = org.hibernate.dialect.MySQL5Dialect spring.jpa.generate-ddl=true spring.jpa.hibernate.ddl-auto = update
repos\SpringBoot-Projects-FullStack-master\Part-8 Spring Boot Real Projects\9.PosilkaAdmin\src\main\resources\application.properties
2
请在Spring Boot框架中完成以下Java代码
public String getActivePlanItemDefinitionId() { return activePlanItemDefinitionId; } public void setActivePlanItemDefinitionId(String activePlanItemDefinitionId) { this.activePlanItemDefinitionId = activePlanItemDefinitionId; } public Set<String> getActivePlanItemDefinitionIds() { ...
} public void setWithoutTenantId(Boolean withoutTenantId) { this.withoutTenantId = withoutTenantId; } public Boolean getWithoutCaseInstanceParentId() { return withoutCaseInstanceParentId; } public void setWithoutCaseInstanceParentId(Boolean withoutCaseInstanceParentId) { ...
repos\flowable-engine-main\modules\flowable-cmmn-rest\src\main\java\org\flowable\cmmn\rest\service\api\history\caze\HistoricCaseInstanceQueryRequest.java
2
请完成以下Java代码
public void setBill_Location_Value_ID(final int Bill_Location_Value_ID) { delegate.setBill_Location_Value_ID(Bill_Location_Value_ID); } @Override public int getBill_User_ID() { return delegate.getBill_User_ID(); } @Override public void setBill_User_ID(final int Bill_User_ID) { delegate.setBill_User_ID(...
} @Override public Optional<DocumentLocation> toPlainDocumentLocation(final IDocumentLocationBL documentLocationBL) { return documentLocationBL.toPlainDocumentLocation(this); } @Override public ContractBillLocationAdapter toOldValues() { InterfaceWrapperHelper.assertNotOldValues(delegate); return new Con...
repos\metasfresh-new_dawn_uat\backend\de.metas.contracts\src\main\java\de\metas\contracts\location\adapter\ContractBillLocationAdapter.java
1
请在Spring Boot框架中完成以下Java代码
public class VATType { @XmlElement(name = "TaxExemption") protected String taxExemption; @XmlElement(name = "Item") protected List<ItemType> item; /** * * Reason for the tax exemption. * * * @return * possible object is * {@link String } ...
* <p> * For example, to add a new item, do as follows: * <pre> * getItem().add(newItem); * </pre> * * * <p> * Objects of the following type(s) are allowed in the list * {@link ItemType } * * */ public List<ItemType> getItem() { if (item == n...
repos\metasfresh-new_dawn_uat\misc\services\camel\de-metas-camel-edi\src\main\java-xjc_ecosio_remadv\at\erpel\schemas\_1p0\documents\VATType.java
2
请完成以下Java代码
public int getAD_Client_ID() { return adClientId; } @Override public void onModelChange(final Object model, final ModelChangeType changeType) throws Exception { for (final IModelInterceptor interceptor : interceptors) { interceptor.onModelChange(model, changeType); } } @Override public void onDocVa...
interceptor.onUserLogin(AD_Org_ID, AD_Role_ID, AD_User_ID); } } @Override public void beforeLogout(final MFSession session) { for (final IUserLoginListener listener : userLoginListeners) { listener.beforeLogout(session); } } @Override public void afterLogout(final MFSession session) { for (final ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\org\adempiere\ad\modelvalidator\CompositeModelInterceptor.java
1
请在Spring Boot框架中完成以下Java代码
public String getName() { return name; } @Override public int getVersion() { return version; } @Override public String getResourceName() { return resourceName; } @Override public String getDeploymentId() { return deploymentId; } @Override public String getDiagramResourceName(...
} @Override public String getTenantId() { return tenantId; } @Override public String getVersionTag() { return versionTag; } @Override public Integer getHistoryTimeToLive() { return historyTimeToLive; } @Override public boolean isStartableInTasklist() { return isStartableInTaskl...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\repository\CalledProcessDefinitionImpl.java
2
请完成以下Java代码
public FeelEngine createInstance() { return feelEngine; } protected FeelEngine createFeelEngine() { FeelToJuelTransform transform = createFeelToJuelTransform(); ExpressionFactory expressionFactory = createExpressionFactory(); ElContextFactory elContextFactory = createElContextFactory(); Cache<T...
try { return new ExpressionFactoryImpl(properties, createTypeConverter()); } catch (ELException e) { throw LOG.unableToInitializeFeelEngine(e); } } protected FeelTypeConverter createTypeConverter() { return new FeelTypeConverter(); } protected ElContextFactory createElContextFactor...
repos\camunda-bpm-platform-master\engine-dmn\feel-juel\src\main\java\org\camunda\bpm\dmn\feel\impl\juel\FeelEngineFactoryImpl.java
1
请完成以下Java代码
public String getCalledElement() { return calledElement; } public void setCalledElement(String calledElement) { this.calledElement = calledElement; } public boolean isInheritVariables() { return inheritVariables; } public void setInheritVariables(boolean inheritVariabl...
CallActivity clone = new CallActivity(); clone.setValues(this); return clone; } public void setValues(CallActivity otherElement) { super.setValues(otherElement); setCalledElement(otherElement.getCalledElement()); setBusinessKey(otherElement.getBusinessKey()); set...
repos\Activiti-develop\activiti-core\activiti-bpmn-model\src\main\java\org\activiti\bpmn\model\CallActivity.java
1
请完成以下Java代码
private static SqlAndParams sqlGeographicalDistance( @NonNull final String locationTableAlias, @NonNull final GeographicalCoordinates addressCoordinates, final int distanceInKm) { return SqlAndParams.builder() .append("geographical_distance(" // + locationTableAlias + "." + I_C_Location.COLU...
final GeoCoordinatesRequest request = GeoCoordinatesRequest.builder() .countryCode2(countryCode2) .postal(filter.getParameterValueAsString(PARAM_Postal, "")) .address(filter.getParameterValueAsString(PARAM_Address1, "")) .city(filter.getParameterValueAsString(PARAM_City, "")) .build(); return Opt...
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\document\geo_location\GeoLocationFilterConverter.java
1
请完成以下Java代码
public static Set<Integer> getOrderLineRepoIds(final Collection<OrderAndLineId> orderAndLineIds) { return orderAndLineIds.stream().map(OrderAndLineId::getOrderLineRepoId).collect(ImmutableSet.toImmutableSet()); } public static Set<OrderId> getOrderIds(final Collection<OrderAndLineId> orderAndLineIds) { return ...
@JsonValue public String toJson() { return orderId.getRepoId() + "_" + orderLineId.getRepoId(); } @JsonCreator public static OrderAndLineId ofJson(@NonNull String json) { try { final int idx = json.indexOf("_"); return ofRepoIds(Integer.parseInt(json.substring(0, idx)), Integer.parseInt(json.substrin...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\de\metas\order\OrderAndLineId.java
1
请完成以下Java代码
public class DefaultLazyPropertyDetector implements EncryptablePropertyDetector { private Singleton<EncryptablePropertyDetector> singleton; /** * <p>Constructor for DefaultLazyPropertyDetector.</p> * * @param environment a {@link org.springframework.core.env.ConfigurableEnvironment} object ...
} private DefaultPropertyDetector createDefault(ConfigurableEnvironment environment) { JasyptEncryptorConfigurationProperties props = JasyptEncryptorConfigurationProperties.bindConfigProps(environment); return new DefaultPropertyDetector(props.getProperty().getPrefix(), props.getProperty().getSuffi...
repos\jasypt-spring-boot-master\jasypt-spring-boot\src\main\java\com\ulisesbocchio\jasyptspringboot\detector\DefaultLazyPropertyDetector.java
1
请在Spring Boot框架中完成以下Java代码
public BigDecimal getQtyCUsPerLU() { return qtyCUsPerLU; } /** * Sets the value of the qtyCUsPerLU property. * * @param value * allowed object is * {@link BigDecimal } * */ public void setQtyCUsPerLU(BigDecimal value) { this.qtyCUsPerLU = val...
* possible object is * {@link BigDecimal } * */ public BigDecimal getQtyCUsPerTUInInvoiceUOM() { return qtyCUsPerTUInInvoiceUOM; } /** * Sets the value of the qtyCUsPerTUInInvoiceUOM property. * * @param value * allowed object is * {@lin...
repos\metasfresh-new_dawn_uat\misc\services\camel\de-metas-camel-edi\src\main\java-xjc_metasfreshinhousev2\de\metas\edi\esb\jaxb\metasfreshinhousev2\EDIDesadvPackItem1PerInOutType.java
2
请完成以下Java代码
protected CustomValueMapper newInstance(Class<?> valueMapperClass) { try { return (CustomValueMapper) valueMapperClass.newInstance(); } catch (InstantiationException e) { throw LOGGER.spinValueMapperInstantiationException(e); } catch (IllegalAccessException e) { throw LOGGER.spinValueMap...
protected Class<?> lookupClass() { try { return Class.forName(SPIN_VALUE_MAPPER_CLASS_NAME); } catch (ClassNotFoundException ignored) { // engine plugin is not on class path => ignore } catch (Throwable e) { throw LOGGER.spinValueMapperException(e); } return null; } }
repos\camunda-bpm-platform-master\engine-dmn\feel-scala\src\main\java\org\camunda\bpm\dmn\feel\impl\scala\spin\SpinValueMapperFactory.java
1
请在Spring Boot框架中完成以下Java代码
public class TaskCommentCollectionResource extends TaskBaseResource { @ApiOperation(value = "List comments on a task", tags = { "Task Comments" }, nickname = "listTaskComments") @ApiResponses(value = { @ApiResponse(code = 200, message = "Indicates the task was found and the comments are returned.")...
Task task = getTaskFromRequestWithoutAccessCheck(taskId); if (comment.getMessage() == null) { throw new FlowableIllegalArgumentException("Comment text is required."); } if (restApiInterceptor != null) { restApiInterceptor.createTaskComment(task, comment); } ...
repos\flowable-engine-main\modules\flowable-rest\src\main\java\org\flowable\rest\service\api\runtime\task\TaskCommentCollectionResource.java
2
请完成以下Java代码
public void fromAnnotation(EnableExternalTaskClient annotation) { String baseUrl = annotation.baseUrl(); setBaseUrl(isNull(baseUrl) ? null : baseUrl); int maxTasks = annotation.maxTasks(); setMaxTasks(isNull(maxTasks) ? null : maxTasks); String workerId = annotation.workerId(); setWorkerId(isN...
setDefaultSerializationFormat(isNull(serializationFormat) ? null : serializationFormat); } protected void configureOrderByCreateTime(EnableExternalTaskClient annotation) { if (EnableExternalTaskClient.STRING_NULL_VALUE.equals(annotation.orderByCreateTime())) { setOrderByCreateTime(null); } else { ...
repos\camunda-bpm-platform-master\spring-boot-starter\starter-client\spring\src\main\java\org\camunda\bpm\client\spring\impl\client\ClientConfiguration.java
1
请在Spring Boot框架中完成以下Java代码
public boolean set(final String key, Serializable value, Long expireTime) { boolean result = false; try { ValueOperations<Serializable, Serializable> operations = redisTemplate.opsForValue(); operations.set(key, value); redisTemplate.expire(key, expireTime, TimeUnit.S...
HashOperations<K, HK, HV> operations = redisTemplate.opsForHash(); operations.putAll(key, map); if (expireTime != null) { redisTemplate.expire(key, expireTime, TimeUnit.SECONDS); } return false; } @Override public <K,HK,HV> Map<HK,HV> getMap(final K key) { ...
repos\SpringBoot-Dubbo-Docker-Jenkins-master\Gaoxi-Order\src\main\java\com\gaoxi\order\service\RedisServiceImpl.java
2
请完成以下Java代码
public String getIsbn() { return isbn; } public void setIsbn(String isbn) { this.isbn = isbn; } @Override public boolean equals(Object obj) { if (this == obj) { return true; } if(obj == null) {
return false; } if (getClass() != obj.getClass()) { return false; } BusinessKeyBook other = (BusinessKeyBook) obj; return Objects.equals(isbn, other.getIsbn()); } @Override public int hashCode() { return Objects.hash(isbn); } }
repos\Hibernate-SpringBoot-master\HibernateSpringBootLombokEqualsAndHashCode\src\main\java\com\app\BusinessKeyBook.java
1
请完成以下Java代码
public Flux<ReactiveSessionInformation> getAllSessions(Object principal) { Authentication authenticationToken = getAuthenticationToken(principal); return this.indexedSessionRepository.findByPrincipalName(authenticationToken.getName()) .flatMapMany((sessionMap) -> Flux.fromIterable(sessionMap.entrySet())) .map...
SpringSessionBackedReactiveSessionInformation(S session) { super(resolvePrincipalName(session), session.getId(), session.getLastAccessedTime()); } private static String resolvePrincipalName(Session session) { String principalName = session .getAttribute(ReactiveFindByIndexNameSessionRepository.PRINCIPAL_...
repos\spring-session-main\spring-session-core\src\main\java\org\springframework\session\security\SpringSessionBackedReactiveSessionRegistry.java
1
请在Spring Boot框架中完成以下Java代码
GraphQlRSocketController graphQlRSocketController(GraphQlRSocketHandler handler) { return new GraphQlRSocketController(handler); } interface JsonEncoderSupplier { Encoder<?> jsonEncoder(); } @Configuration(proxyBeanMethods = false) @ConditionalOnBean(JsonMapper.class) @ConditionalOnProperty(name = "spring...
static class NoJacksonOrJackson2Preferred extends AnyNestedCondition { NoJacksonOrJackson2Preferred() { super(ConfigurationPhase.PARSE_CONFIGURATION); } @ConditionalOnMissingClass("tools.jackson.databind.json.JsonMapper") static class NoJackson { } @ConditionalOnProperty(name = "spring.graphql.rsocke...
repos\spring-boot-4.0.1\module\spring-boot-graphql\src\main\java\org\springframework\boot\graphql\autoconfigure\rsocket\GraphQlRSocketAutoConfiguration.java
2
请在Spring Boot框架中完成以下Java代码
public String getLastName() { return lastName; } /** * Sets the last name. * * @param lastName the new last name */ public void setLastName(String lastName) { this.lastName = lastName; } /** * Gets the user name. * * @return the user name */ public String getUserName() { return userName;...
} /* (non-Javadoc) * @see java.lang.Object#equals(java.lang.Object) */ @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; UserDTO other = (UserDTO) obj; if (emailAddress == null) { if (...
repos\spring-boot-microservices-master\user-webservice\src\main\java\com\rohitghatol\microservices\user\dto\UserDTO.java
2
请在Spring Boot框架中完成以下Java代码
public PasswordEncoder passwordEncoder() { return new BCryptPasswordEncoder(); } @Bean public PersistentTokenRepository persistentTokenRepository() { JdbcTokenRepositoryImpl jdbcTokenRepository = new JdbcTokenRepositoryImpl(); jdbcTokenRepository.setDataSource(dataSource); j...
.and() .rememberMe() .tokenRepository(persistentTokenRepository()) // 配置 token 持久化仓库 .tokenValiditySeconds(3600) // remember 过期时间,单为秒 .userDetailsService(userDetailService) // 处理自动登录逻辑 .and() .authorizeReques...
repos\SpringAll-master\37.Spring-Security-RememberMe\src\main\java\cc\mrbird\security\browser\BrowserSecurityConfig.java
2
请完成以下Java代码
public static boolean isPerfectSquareByUsingBinarySearch(long low, long high, long number) { long check = (low + high) / 2L; if (high < low) return false; if (number == check * check) { return true; } else if (number < check * check) { high = check - 1...
while (x1 > x2) { x1 = (x1 + x2) / 2L; x2 = n / x1; } return x1 == x2 && n % x1 == 0L; } public static boolean isPerfectSquareWithOptimization(long n) { if (n < 0) return false; switch ((int) (n & 0xF)) { case 0: case 1: case 4: ca...
repos\tutorials-master\core-java-modules\core-java-numbers-4\src\main\java\com\baeldung\perfectsquare\PerfectSquareUtil.java
1
请完成以下Java代码
public class ImportTest extends BaseTest { @Before public void before() { super.before(ImportConfig.class); } @Test public void contextTest() { PrintSpringBeanUtil.printlnBean(context); System.out.println("开始获取容器中的Bean"); AnimalFactoryBean animalFactoryBean = conte...
AnimalFactoryBean factoryBean = (AnimalFactoryBean) context.getBean("&monkeyTestBean"); System.out.println(factoryBean); MonkeyTestBean monkeyTestBean = (MonkeyTestBean) context.getBean("monkeyTestBean"); MonkeyTestBean monkeyTestBean2 = context.getBean(MonkeyTestBean.class); System.out...
repos\spring-boot-student-master\spring-boot-student-spring\src\main\java\com\xiaolyuh\iimport\ImportTest.java
1
请在Spring Boot框架中完成以下Java代码
public boolean hasPermission(SecurityUser user, Operation operation, EntityId entityId, HasTenantId entity) { if (entity.getTenantId() == null || entity.getTenantId().isNullUid()) { return operation == Operation.READ; } if (!user.getTenantId().equals(entity.getTenantI...
public boolean hasPermission(SecurityUser user, Operation operation, AiModelId entityId, AiModel entity) { return user.getTenantId().equals(entity.getTenantId()); } }; private static final PermissionChecker<ApiKeyId, ApiKeyInfo> apiKeysPermissionChecker = new PermissionChecker<>() { ...
repos\thingsboard-master\application\src\main\java\org\thingsboard\server\service\security\permission\TenantAdminPermissions.java
2
请在Spring Boot框架中完成以下Java代码
public static double editDistanceAll(String s1, String s2) { return Math.round(editDistance(s1, s2) / max(s1.length(), s2.length()) * 100); } public static String clean(String s) { String ss; ss = s.replace(".", " ").replace(",", " ").replace(";", " ").replace("*", " ").replace("#", " "...
count = 1; return Math.round(d / count * 100); } public static double similarity2(String s1, String s2) { return editDistanceWord(s1, s2); } @Override public int compare(Address o1, Address o2) { double f1 = similarity2(o1.getAddr(), baseToCompare); double f2 = sim...
repos\SpringBoot-Projects-FullStack-master\Part-9.SpringBoot-React-Projects\Project-2.SpringBoot-React-ShoppingMall\fullstack\backend\src\main\java\com\urunov\service\taxiMaster\StringSimilarity.java
2
请完成以下Java代码
public Void execute(CommandContext commandContext) { ensureNotNull(BadUserRequestException.class, "Batch id must not be null", "batch id", batchId); BatchManager batchManager = commandContext.getBatchManager(); BatchEntity batch = batchManager.findBatchById(batchId); ensureNotNull(BadUserRequestExcept...
protected AbstractSetJobDefinitionStateCmd createSetJobDefinitionStateCommand(String jobDefinitionId) { AbstractSetJobDefinitionStateCmd suspendJobDefinitionCmd = createSetJobDefinitionStateCommand(new UpdateJobDefinitionSuspensionStateBuilderImpl() .byJobDefinitionId(jobDefinitionId) .includeJobs(true)...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cmd\AbstractSetBatchStateCmd.java
1
请在Spring Boot框架中完成以下Java代码
public String getPreviousDecisionDefinitionId() { ensurePreviousDecisionDefinitionIdInitialized(); return previousDecisionDefinitionId; } public void setPreviousDecisionDefinitionId(String previousDecisionDefinitionId) { this.previousDecisionDefinitionId = previousDecisionDefinitionId; } protected...
} @Override public String toString() { return "DecisionDefinitionEntity{" + "id='" + id + '\'' + ", name='" + name + '\'' + ", category='" + category + '\'' + ", key='" + key + '\'' + ", version=" + version + ", versionTag=" + versionTag + ", decisionRequirementsDefini...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\dmn\entity\repository\DecisionDefinitionEntity.java
2
请完成以下Java代码
public Integer getStatus() { return status; } public void setStatus(Integer status) { this.status = status; } public Date getCreateTime() { return createTime; } public void setCreateTime(Date createTime) { this.createTime = createTime; }
@Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append(getClass().getSimpleName()); sb.append(" ["); sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id); sb.append(", name=").append(name); sb.append(", sort=")...
repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\OmsOrderReturnReason.java
1
请完成以下Java代码
public OrderItemBuilder datePromised(@NonNull final ZonedDateTime datePromised) { innerBuilder.datePromised(datePromised); return this; } public OrderItemBuilder dateOrdered(@Nullable final ZonedDateTime dateOrdered) { innerBuilder.dateOrdered(dateOrdered); return this; } public OrderItemBuild...
{ final PurchaseCandidateId id = getId(); Check.assumeNotNull(id, "purchase candidate shall be saved: {}", this); Check.assumeEquals(id, purchaseOrderItem.getPurchaseCandidateId(), "The given purchaseOrderItem's purchaseCandidateId needs to be equal to this instance's id; purchaseOrderItem={}; this={}", ...
repos\metasfresh-new_dawn_uat\backend\de.metas.purchasecandidate.base\src\main\java\de\metas\purchasecandidate\PurchaseCandidate.java
1
请完成以下Java代码
public class X_R_StandardResponse extends PO implements I_R_StandardResponse, I_Persistent { /** * */ private static final long serialVersionUID = 20090915L; /** Standard Constructor */ public X_R_StandardResponse (Properties ctx, int R_StandardResponse_ID, String trxName) { super (ctx, R_Sta...
set_Value (COLUMNNAME_ResponseText, ResponseText); } /** Get Response Text. @return Request Response Text */ public String getResponseText () { return (String)get_Value(COLUMNNAME_ResponseText); } /** Set Standard Response. @param R_StandardResponse_ID Request Standard Response */ public void ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_R_StandardResponse.java
1
请完成以下Java代码
public java.math.BigDecimal getQtyOrdered_TU () { BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_QtyOrdered_TU); if (bd == null) return BigDecimal.ZERO; return bd; } /** Set Ausliefermenge (LU). @param QtyToDeliver_LU Ausliefermenge (LU) */ @Override public void setQtyToDeliver_LU (java.math.BigD...
/** Set Ausliefermenge (TU). @param QtyToDeliver_TU Ausliefermenge (TU) */ @Override public void setQtyToDeliver_TU (java.math.BigDecimal QtyToDeliver_TU) { set_Value (COLUMNNAME_QtyToDeliver_TU, QtyToDeliver_TU); } /** Get Ausliefermenge (TU). @return Ausliefermenge (TU) */ @Override public java.math...
repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java-gen\de\metas\tourplanning\model\X_M_Tour_Instance.java
1
请完成以下Java代码
public String getEventType() { return eventType; } public void setEventType(String eventType) { this.eventType = eventType; } public String getEventName() { return eventName; } public void setEventName(String eventName) { this.eventName = eventName; } ...
public Date getCreated() { return created; } public void setCreated(Date created) { this.created = created; } public String getProcessDefinitionId() { return processDefinitionId; } public void setProcessDefinitionId(String processDefinitionId) { this.processDef...
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\persistence\entity\EventSubscriptionEntityImpl.java
1
请完成以下Java代码
public String getPart(final int index) { return parts.get(index); } public int getPartAsInt(final int index) { try { final String partStr = getPart(index); return Integer.parseInt(partStr); } catch (final Exception ex) { throw new AdempiereException("Cannot extract part with index " + index + ...
{ if (windowId.equals(newWindowId)) { return this; } final ImmutableList<String> newParts = ImmutableList.<String>builder() .add(newWindowId.toJson()) .addAll(parts.subList(1, parts.size())) .build(); final String newViewId = JOINER.join(newParts); return new ViewId(newViewId, newParts, ne...
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\view\ViewId.java
1
请在Spring Boot框架中完成以下Java代码
public class Access implements ReferenceListAwareEnum { public static final Access LOGIN = new Access("LOGIN", "L"); public static final Access READ = new Access("READ", X_AD_User_Record_Access.ACCESS_Read); public static final Access WRITE = new Access("WRITE", X_AD_User_Record_Access.ACCESS_Write); public static ...
public String toString() { return getName(); } @Override @JsonValue public @NotNull String getCode() { return code; } public boolean isReadOnly() { return READ.equals(this); } public boolean isReadWrite() { return WRITE.equals(this); } }
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\security\permissions\Access.java
2
请完成以下Java代码
public void setProcessDefinitionCreatePermissionChecks(List<PermissionCheck> processDefinitionCreatePermissionChecks) { this.processDefinitionCreatePermissionChecks = processDefinitionCreatePermissionChecks; } public List<PermissionCheck> getProcessDefinitionCreatePermissionChecks() { return processDefinit...
return cachedCandidateGroups; } if(authorizationUserId != null) { List<Group> groups = Context.getCommandContext() .getReadOnlyIdentityProvider() .createGroupQuery() .groupMember(authorizationUserId) .list(); cachedCandidateGroups = groups.stream().map(Group:...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\ProcessDefinitionQueryImpl.java
1
请完成以下Java代码
class ProjectType { private final String id; private final String name; private final String action; private final boolean defaultType; private final Map<String, String> tags = new HashMap<>(); ProjectType(String id, String name, String action, boolean defaultType, @Nullable Map<String, String> tags) { th...
String getName() { return this.name; } String getAction() { return this.action; } boolean isDefaultType() { return this.defaultType; } Map<String, String> getTags() { return Collections.unmodifiableMap(this.tags); } }
repos\spring-boot-4.0.1\cli\spring-boot-cli\src\main\java\org\springframework\boot\cli\command\init\ProjectType.java
1
请完成以下Java代码
public static HuPackingInstructionsId ofRepoIdOrNull(final int repoId) { return repoId > 0 ? ofRepoId(repoId) : null; } public static int toRepoId(@Nullable final HuPackingInstructionsId HuPackingInstructionsId) { return HuPackingInstructionsId != null ? HuPackingInstructionsId.getRepoId() : -1; } public st...
return repoId == TEMPLATE.repoId; } public boolean isVirtual() { return isVirtualRepoId(repoId); } public static boolean isVirtualRepoId(final int repoId) { return repoId == VIRTUAL.repoId; } public boolean isRealPackingInstructions() { return isRealPackingInstructionsRepoId(repoId); } public stat...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\handlingunits\HuPackingInstructionsId.java
1
请完成以下Java代码
public class FindBugsDemo { private static final DateFormat yyyyMMdd = new SimpleDateFormat("yyyy-MM-dd"); public static String yyyyMMddForMat(Date date) { return yyyyMMdd.format(date); } public static int getRanDom() { return new Random().nextInt(); } public static int round...
} } } public static String trimString(String str) { str.trim(); return str; } @Override public boolean equals(Object obj) { return super.equals(obj); } }
repos\springboot-demo-master\findbug\src\main\java\com\et\findbug\FindBugsDemo.java
1
请完成以下Java代码
public void setReference (String Reference) { set_Value (COLUMNNAME_Reference, Reference); } /** Get Reference. @return Reference for this record */ public String getReference () { return (String)get_Value(COLUMNNAME_Reference); } public I_R_RequestProcessor getR_RequestProcessor() throws RuntimeExce...
else set_ValueNoCheck (COLUMNNAME_R_RequestProcessorLog_ID, Integer.valueOf(R_RequestProcessorLog_ID)); } /** Get Request Processor Log. @return Result of the execution of the Request Processor */ public int getR_RequestProcessorLog_ID () { Integer ii = (Integer)get_Value(COLUMNNAME_R_RequestProcessorL...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_R_RequestProcessorLog.java
1
请完成以下Java代码
public void setDescription(final String description) { this.description = description; this.descriptionSet = true; } public void setSales(final Boolean sales) { this.sales = sales; this.salesSet = true; } public void setSalesDefault(final Boolean salesDefault) { this.salesDefault = salesDefault; th...
public void setPurchaseDefault(final Boolean purchaseDefault) { this.purchaseDefault = purchaseDefault; this.purchaseDefaultSet = true; } public void setSubjectMatter(final Boolean subjectMatter) { this.subjectMatter = subjectMatter; this.subjectMatterSet = true; } public void setSyncAdvise(final SyncAd...
repos\metasfresh-new_dawn_uat\misc\de-metas-common\de-metas-common-bpartner\src\main\java\de\metas\common\bpartner\v1\request\JsonRequestContact.java
1
请在Spring Boot框架中完成以下Java代码
public class WFNode { @NonNull WFNodeId id; @NonNull ClientId clientId; boolean active; @NonNull ITranslatableString name; @NonNull ITranslatableString description; @NonNull ITranslatableString help; @Nullable WFResponsibleId responsibleId; int priority; @NonNull Duration dynPriorityUnitDuration; @NonN...
// Action: Set Variable String attributeValue; // // Action: User Choice boolean userApproval; // // Action: Open Form int adFormId; // // Action: Open Window AdWindowId adWindowId; // // Action: Mail EMailAddress emailTo; WFNodeEmailRecipient emailRecipient; MailTemplateId mailTemplateId; // // A...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\workflow\WFNode.java
2
请完成以下Spring Boot application配置
## Redis 配置 ## Redis服务器地址 spring.redis.host=127.0.0.1 ## Redis服务器连接端口 spring.redis.port=6379 ## Redis服务器连接密码(默认为空) spring.redis.password= # 连接超时时间(毫秒) spring.redis.timeout=5000 ## MongoDB spring.data.mongodb.host=localhost spring.data.mongodb.databas
e=admin spring.data.mongodb.port=27017 spring.data.mongodb.username=admin spring.data.mongodb.password=admin
repos\springboot-learning-example-master\springboot-webflux-7-redis-cache\src\main\resources\application.properties
2
请在Spring Boot框架中完成以下Java代码
public java.lang.String getExternalUrl() { return get_ValueAsString(COLUMNNAME_ExternalUrl); } @Override public void setMilestone_DueDate (final @Nullable java.sql.Timestamp Milestone_DueDate) { set_Value (COLUMNNAME_Milestone_DueDate, Milestone_DueDate); } @Override public java.sql.Timestamp getMileston...
} @Override public void setS_Milestone_ID (final int S_Milestone_ID) { if (S_Milestone_ID < 1) set_ValueNoCheck (COLUMNNAME_S_Milestone_ID, null); else set_ValueNoCheck (COLUMNNAME_S_Milestone_ID, S_Milestone_ID); } @Override public int getS_Milestone_ID() { return get_ValueAsInt(COLUMNNAME_S_Mi...
repos\metasfresh-new_dawn_uat\backend\de.metas.serviceprovider\src\main\java-gen\de\metas\serviceprovider\model\X_S_Milestone.java
2
请完成以下Java代码
public static String encodeBase64(final byte[] b) { return BaseEncoding.base64().encode(b); } // metas: 03749 public static byte[] decodeBase64(final String str) { return BaseEncoding.base64().decode(str); } // 03743 public static void writeBytes(final File file, final byte[] data) { FileOutputStream o...
/** * Smart converting given exception to string * * @param e * @return */ public static String getErrorMsg(Throwable e) { // save the exception for displaying to user String msg = e.getLocalizedMessage(); if (Check.isEmpty(msg, true)) { msg = e.getMessage(); } if (Check.isEmpty(msg, true)) ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-legacy\org\compiere\util\Util.java
1
请完成以下Java代码
public Optional<BPPurchaseSchedule> findByDate(@NonNull final LocalDate date) { return schedules.stream() .filter(schedule -> !schedule.getValidFrom().isAfter(date)) .findFirst(); } } public BPPurchaseSchedule save(@NonNull final BPPurchaseSchedule schedule) { final I_C_BP_PurchaseSchedule schedu...
} private static void setDaysOfWeek(@NonNull final I_C_BP_PurchaseSchedule scheduleRecord, @NonNull final ImmutableSet<DayOfWeek> daysOfWeek) { if (daysOfWeek.contains(DayOfWeek.MONDAY)) { scheduleRecord.setOnMonday(true); } if (daysOfWeek.contains(DayOfWeek.TUESDAY)) { scheduleRecord.setOnTuesday(tr...
repos\metasfresh-new_dawn_uat\backend\de.metas.purchasecandidate.base\src\main\java\de\metas\purchasecandidate\BPPurchaseScheduleRepository.java
1
请在Spring Boot框架中完成以下Java代码
public CommonResult<List<CartPromotionItem>> listPromotion(@RequestParam(required = false) List<Long> cartIds) { List<CartPromotionItem> cartPromotionItemList = cartItemService.listPromotion(memberService.getCurrentMember().getId(), cartIds); return CommonResult.success(cartPromotionItemList); } ...
int count = cartItemService.delete(memberService.getCurrentMember().getId(), ids); if (count > 0) { return CommonResult.success(count); } return CommonResult.failed(); } @ApiOperation("清空当前会员的购物车") @RequestMapping(value = "/clear", method = RequestMethod.POST) @Respo...
repos\mall-master\mall-portal\src\main\java\com\macro\mall\portal\controller\OmsCartItemController.java
2
请完成以下Java代码
public ProcessEngineConfigurationImpl setAsyncExecutorExecuteAsyncRunnableFactory( ExecuteAsyncRunnableFactory asyncExecutorExecuteAsyncRunnableFactory ) { this.asyncExecutorExecuteAsyncRunnableFactory = asyncExecutorExecuteAsyncRunnableFactory; return this; } public int getAsyncExe...
return eventSubscriptionPayloadMappingProvider; } public void setEventSubscriptionPayloadMappingProvider( EventSubscriptionPayloadMappingProvider eventSubscriptionPayloadMappingProvider ) { this.eventSubscriptionPayloadMappingProvider = eventSubscriptionPayloadMappingProvider; } pu...
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\cfg\ProcessEngineConfigurationImpl.java
1
请完成以下Java代码
public ProcessPreconditionsResolution checkPreconditionsApplicable(final @NonNull IProcessPreconditionsContext context) { if (!context.isSingleSelection()) { return ProcessPreconditionsResolution.rejectBecauseNotSingleSelection().toInternal(); } final SAPGLJournalId glJournalId = SAPGLJournalId.ofRepoId(co...
@Override protected String doIt() { final SAPGLJournal createdJournal = glJournalService.copy(SAPGLJournalCopyRequest.builder() .sourceJournalId(SAPGLJournalId.ofRepoId(getRecord_ID())) .dateDoc(dateDoc) .negateAmounts(negateAmounts) ...
repos\metasfresh-new_dawn_uat\backend\de.metas.acct.base\src\main\java\de\metas\acct\gljournal_sap\process\SAP_GLJournal_CopyDocument.java
1
请在Spring Boot框架中完成以下Java代码
public String getUserGood(UserPrincipal userPrincipal){ User user = userRepository.findById(userPrincipal.getId()).orElse(null); if(user != null){ Orders order = orderRepository.findFirstByStatusAndUser(OrderStatus.NEW, user).orElse(null); if(order != null){ retu...
} } } if(order == null){ order = new Orders(); order.setUser(user); order.setStatus(OrderStatus.NEW); orderRepository.save(order); orderDetails = new OrderDetails(); orderDetails.setQu...
repos\SpringBoot-Projects-FullStack-master\Part-9.SpringBoot-React-Projects\Project-2.SpringBoot-React-ShoppingMall\fullstack\backend\src\main\java\com\urunov\service\OrderDetailsService.java
2
请完成以下Java代码
public class MPaySelection extends X_C_PaySelection { private static final long serialVersionUID = -6521282913549455131L; public MPaySelection(Properties ctx, int C_PaySelection_ID, String trxName) { super(ctx, C_PaySelection_ID, trxName); if (is_new()) { setTotalAmt(BigDecimal.ZERO); setIsApproved(fals...
public MPaySelection(Properties ctx, ResultSet rs, String trxName) { super(ctx, rs, trxName); } @Override public String toString() { StringBuilder sb = new StringBuilder("MPaySelection["); sb.append(get_ID()).append(",").append(getName()) .append("]"); return sb.toString(); } }
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java-legacy\org\compiere\model\MPaySelection.java
1
请完成以下Java代码
public boolean isAny() { return type == BPartnerClassifierType.ANY; } public boolean isNone() { return type == BPartnerClassifierType.NONE; } public boolean isSpecificBPartner() { return type == BPartnerClassifierType.SPECIFIC; } public BPartnerId getBpartnerId() { if (type != BPartnerClassifierTyp...
{ return true; } else if (isNone()) { return other.isAny() || other.isNone(); } else if (isSpecificBPartner()) { return other.isAny() || this.equals(other); } else { throw new IllegalStateException("Case not handled: this=" + this + ", other=" + other); } } }
repos\metasfresh-new_dawn_uat\backend\de.metas.material\commons\src\main\java\de\metas\material\commons\attributes\clasifiers\BPartnerClassifier.java
1
请完成以下Java代码
public class Jackson2JmxOperationResponseMapper implements JmxOperationResponseMapper { private final ObjectMapper objectMapper; private final JavaType listType; private final JavaType mapType; public Jackson2JmxOperationResponseMapper(@Nullable ObjectMapper objectMapper) { this.objectMapper = (objectMapper !...
@Override @Contract("!null -> !null") public @Nullable Object mapResponse(@Nullable Object response) { if (response == null) { return null; } if (response instanceof CharSequence) { return response.toString(); } if (response.getClass().isArray() || response instanceof Collection) { return this.obje...
repos\spring-boot-4.0.1\module\spring-boot-actuator\src\main\java\org\springframework\boot\actuate\endpoint\jmx\Jackson2JmxOperationResponseMapper.java
1
请完成以下Java代码
protected HistoricActivityInstanceEntity findHistoricActivityInstance(ExecutionEntity execution, String activityId, boolean endTimeMustBeNull) { // No use looking for the HistoricActivityInstance when no activityId is provided. if (activityId == null) { return null; } Strin...
protected String getProcessDefinitionId(VariableInstanceEntity variable, ExecutionEntity sourceActivityExecution) { String processDefinitionId = null; if (sourceActivityExecution != null) { processDefinitionId = sourceActivityExecution.getProcessDefinitionId(); } else if (variable.ge...
repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\history\AbstractHistoryManager.java
1
请完成以下Java代码
public String getName() { return name; } public void setName(String name) { this.name = name; } public byte getAge() { return age; } public void setAge(byte age) { this.age = age; } public short getUidNumber() { return uidNumber; } pub...
return weight; } public void setWeight(double weight) { this.weight = weight; } public char getGender() { return gender; } public void setGender(char gender) { this.gender = gender; } public boolean isActive() { return active; } public void se...
repos\tutorials-master\core-java-modules\core-java-reflection\src\main\java\com\baeldung\reflection\access\privatefields\Person.java
1
请完成以下Java代码
public Iterator<T> iterator() { Collection<T> modelElementCollection = ModelUtil.getModelElementCollection(getView(modelElement), modelElement.getModelInstance()); return modelElementCollection.iterator(); } public Object[] toArray() { Collection<T> modelElementCollection = ModelUti...
performClearOperation(modelElement, view); } public boolean remove(Object e) { if(!isMutable) { throw new UnsupportedModelOperationException("remove()", "collection is immutable"); } ModelUtil.ensureInstanceOf(e, ModelElementInstanceImpl.class); return performRemov...
repos\camunda-bpm-platform-master\model-api\xml-model\src\main\java\org\camunda\bpm\model\xml\impl\type\child\ChildElementCollectionImpl.java
1
请完成以下Java代码
public int getRecordId() { return recordId; } @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + recordId; result = prime * result + tableId; return result; } @Override public boolean equals(Object obj)
{ if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; TableRecordIdPair other = (TableRecordIdPair)obj; if (recordId != other.recordId) return false; if (tableId != other.tableId) return false; return true; } } }
repos\metasfresh-new_dawn_uat\backend\de.metas.edi\src\main\java\de\metas\edi\async\spi\impl\EDIWorkpackageProcessor.java
1
请完成以下Java代码
public Object getValue(ValueFields valueFields) { CommandContext commandContext = CommandContextUtil.getCommandContext(); if (commandContext != null) { return getValue(valueFields, commandContext); } else { return processEngineConfiguration.getCommandExecutor() ...
List<? extends ExecutionEntity> childExecutions = multiInstanceRootExecution.getExecutions(); int nrOfActiveInstances = (int) childExecutions.stream().filter(execution -> execution.isActive() && !(execution.getCurrentFlowElement() instanceof BoundaryEvent)).count(); if (ParallelMultiInstance...
repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\variable\ParallelMultiInstanceLoopVariableType.java
1
请完成以下Java代码
public int getM_AttributeSetInstance_ID () { Integer ii = (Integer)get_Value(COLUMNNAME_M_AttributeSetInstance_ID); if (ii == null) return 0; return ii.intValue(); } public I_M_MovementLine getM_MovementLine() throws RuntimeException { return (I_M_MovementLine)MTable.get(getCtx(), I_M_MovementLine....
@return ID/ColumnName pair */ public KeyNamePair getKeyNamePair() { return new KeyNamePair(get_ID(), String.valueOf(getM_MovementLine_ID())); } /** Set Movement Quantity. @param MovementQty Quantity of a product moved. */ public void setMovementQty (BigDecimal MovementQty) { set...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_M_MovementLineMA.java
1
请完成以下Java代码
public void setC_Queue_WorkPackage_Notified_ID (int C_Queue_WorkPackage_Notified_ID) { if (C_Queue_WorkPackage_Notified_ID < 1) set_ValueNoCheck (COLUMNNAME_C_Queue_WorkPackage_Notified_ID, null); else set_ValueNoCheck (COLUMNNAME_C_Queue_WorkPackage_Notified_ID, Integer.valueOf(C_Queue_WorkPackage_Notifie...
set_Value (COLUMNNAME_IsNotified, Boolean.valueOf(IsNotified)); } /** Get Notified. @return Notified */ @Override public boolean isNotified () { Object oo = get_Value(COLUMNNAME_IsNotified); if (oo != null) { if (oo instanceof Boolean) return ((Boolean)oo).booleanValue(); return "Y".equa...
repos\metasfresh-new_dawn_uat\backend\de.metas.async\src\main\java-gen\de\metas\async\model\X_C_Queue_WorkPackage_Notified.java
1
请完成以下Java代码
public void onQualityNoteChanged(final de.metas.request.model.I_R_Request request) { final QualityNoteId qualityNoteId = QualityNoteId.ofRepoIdOrNull(request.getM_QualityNote_ID()); if (qualityNoteId == null) { // nothing to do return; } final I_M_QualityNote qualityNote = Services.get(IQualityNoteDAO....
@ModelChange(timings = { ModelValidator.TYPE_BEFORE_NEW }) public void setSalesRep(final I_R_Request request) { final Properties ctx = InterfaceWrapperHelper.getCtx(request); final RoleId adRoleId = Env.getLoggedRoleId(ctx); final Role role = Services.get(IRoleDAO.class).getById(adRoleId); // task #577: The ...
repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\request\model\validator\R_Request.java
1
请完成以下Java代码
public class ImmutableAuthenticationExtensionsClientInput<T> implements AuthenticationExtensionsClientInput<T> { @Serial private static final long serialVersionUID = -1738152485672656808L; /** * https://www.w3.org/TR/webauthn-3/#sctn-authenticator-credential-properties-extension */ public static final Authent...
* @param input the input. */ public ImmutableAuthenticationExtensionsClientInput(String extensionId, T input) { this.extensionId = extensionId; this.input = input; } @Override public String getExtensionId() { return this.extensionId; } @Override public T getInput() { return this.input; } }
repos\spring-security-main\webauthn\src\main\java\org\springframework\security\web\webauthn\api\ImmutableAuthenticationExtensionsClientInput.java
1
请完成以下Java代码
private ZonedDateTime extractPreparationTime(@NonNull final I_M_ShipmentSchedule record) { return shipmentScheduleBL.getPreparationDate(record); } private Quantity extractQtyCUToDeliver(@NonNull final I_M_ShipmentSchedule record) { return shipmentScheduleBL.getQtyToDeliver(record); } private BigDecimal extr...
{ final OrderAndLineId salesOrderAndLineId = extractSalesOrderAndLineId(record); if (salesOrderAndLineId == null) { return 0; } final I_C_OrderLine salesOrderLine = salesOrderLines.get(salesOrderAndLineId); if (salesOrderLine == null) { return 0; } return salesOrderLine.getLine(); } }
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\shipment_candidates_editor\ShipmentCandidateRowsLoader.java
1