instruction
string
input
string
output
string
source_file
string
priority
int64
请在Spring Boot框架中完成以下Java代码
public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception { endpoints .authenticationManager(auth) .tokenStore(tokenStore()) ; } @Override public void configure(ClientDetailsServiceConfigurer clients) thr...
.authorizedGrantTypes("client_credentials", "refresh_token") .scopes("server") ; } @Configuration @Order(-20) protected static class AuthenticationManagerConfiguration extends GlobalAuthenticationConfigurerAdapter { @Autowired private DataSource dataSource; ...
repos\spring-boot-cloud-master\auth-service\src\main\java\cn\zhangxd\auth\config\OAuthConfiguration.java
2
请完成以下Java代码
protected void initCommandContextCloseListener() { this.commandContextCloseListener = new LoggingSessionCommandContextCloseListener(this, loggingListener, objectMapper); } public void addLoggingData(String type, ObjectNode data, String engineType) { if (loggingData == null) { l...
public void flush() { } @Override public void close() { } public List<ObjectNode> getLoggingData() { return loggingData; } public void setLoggingData(List<ObjectNode> loggingData) { this.loggingData = loggingData; } }
repos\flowable-engine-main\modules\flowable-engine-common\src\main\java\org\flowable\common\engine\impl\logging\LoggingSession.java
1
请完成以下Java代码
public InventoryQueryBuilder onlyResponsibleId(@NonNull final UserId responsibleId) { return onlyResponsibleIds(InSetPredicate.only(responsibleId)); } public InventoryQueryBuilder onlyWarehouseIdOrAny(@Nullable final WarehouseId warehouseId) { return onlyWarehouseIds(InSetPredicate.onlyOrAny(warehouseId)...
public <T> InventoryQueryBuilder excludeInventoryIdsOf(@Nullable Collection<T> collection, @NonNull final Function<T, InventoryId> inventoryIdFunction) { if (collection == null || collection.isEmpty()) {return this;} final ImmutableSet<InventoryId> inventoryIds = collection.stream() .filter(Objects::nonNu...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\de\metas\inventory\InventoryQuery.java
1
请完成以下Java代码
public void follow(User user) { follow(user.getId()); } public void unfollow(User user) { unfollow(user.getId()); } public void favorite(Article article) { article.incrementFavoritesCount(); favoriteArticleIds.add(article.getId()); } public void unfavorite(Arti...
favoriteArticleIds.remove(article.getId()); } public boolean isFavoriteArticle(Article article) { return favoriteArticleIds.contains(article.getId()); } public boolean isFollowing(User user) { return followingIds.contains(user.getId()); } public boolean isFollower(User user) {...
repos\realworld-spring-webflux-master\src\main\java\com\realworld\springmongo\user\User.java
1
请完成以下Java代码
public String getPropertyName() { return this.propertyName; } /** * Return the actual origin for the source if known. * @return the actual source origin * @since 3.2.8 */ @Override public @Nullable Origin getOrigin() { return this.origin; } @Override public @Nullable Origin getParent() { return (...
public String toString() { return (this.origin != null) ? this.origin.toString() : "\"" + this.propertyName + "\" from property source \"" + this.propertySource.getName() + "\""; } /** * Get an {@link Origin} for the given {@link PropertySource} and * {@code propertyName}. Will either return an {@link Orig...
repos\spring-boot-4.0.1\core\spring-boot\src\main\java\org\springframework\boot\origin\PropertySourceOrigin.java
1
请完成以下Java代码
public JobQuery orderByJobId() { return orderBy(JobQueryProperty.JOB_ID); } public JobQuery orderByProcessInstanceId() { return orderBy(JobQueryProperty.PROCESS_INSTANCE_ID); } public JobQuery orderByJobRetries() { return orderBy(JobQueryProperty.RETRIES); } public Job...
public String getProcessDefinitionId() { return processDefinitionId; } public boolean isOnlyTimers() { return onlyTimers; } public boolean isOnlyMessages() { return onlyMessages; } public Date getDuedateHigherThan() { return duedateHigherThan; } public...
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\JobQueryImpl.java
1
请完成以下Java代码
public class GroupDetails implements Group, Serializable { private static final long serialVersionUID = 1L; protected final String id; protected final String name; protected final String type; protected GroupDetails(String id, String name, String type) { this.id = id; this.name = ...
@Override public void setType(String string) { // Not supported } public static GroupDetails create(Group group) { return new GroupDetails(group.getId(), group.getName(), group.getType()); } public static List<GroupDetails> create(List<Group> groups) { List<GroupDetails> g...
repos\flowable-engine-main\modules\flowable-spring-security\src\main\java\org\flowable\spring\security\GroupDetails.java
1
请完成以下Java代码
public final class Cache implements TreeCache { private final ConcurrentMap<String, Tree> map; private final ConcurrentLinkedQueue<String> queue; private final AtomicInteger size; private final int capacity; /** * Creates a new cache with the specified capacity * and default concurrency ...
} public Tree get(String expression) { return map.get(expression); } public void put(String expression, Tree tree) { if (map.putIfAbsent(expression, tree) == null) { queue.offer(expression); if (size.incrementAndGet() > capacity) { size.decrementAndG...
repos\Activiti-develop\activiti-core-common\activiti-juel-jakarta\src\main\java\org\activiti\core\el\juel\tree\impl\Cache.java
1
请在Spring Boot框架中完成以下Java代码
public AuthenticationManager authManager(HttpSecurity http) throws Exception { return http.getSharedObject(AuthenticationManagerBuilder.class) .authenticationProvider(kerberosAuthenticationProvider()) .authenticationProvider(kerberosServiceAuthenticationProvider()) .build(); ...
return provider; } @Bean public SunJaasKerberosTicketValidator sunJaasKerberosTicketValidator() { SunJaasKerberosTicketValidator ticketValidator = new SunJaasKerberosTicketValidator(); ticketValidator.setServicePrincipal("HTTP/demo.kerberos.bealdung.com@baeldung.com"); ticketValidat...
repos\tutorials-master\spring-security-modules\spring-security-oauth2-sso\spring-security-sso-kerberos\src\main\java\com\baeldung\intro\config\WebSecurityConfig.java
2
请在Spring Boot框架中完成以下Java代码
public CommonResult create(@RequestBody List<SmsHomeRecommendSubject> homeRecommendSubjectList) { int count = recommendSubjectService.create(homeRecommendSubjectList); if (count > 0) { return CommonResult.success(count); } return CommonResult.failed(); } @ApiOperatio...
@RequestMapping(value = "/update/recommendStatus", method = RequestMethod.POST) @ResponseBody public CommonResult updateRecommendStatus(@RequestParam("ids") List<Long> ids, @RequestParam Integer recommendStatus) { int count = recommendSubjectService.updateRecommendStatus(ids, recommendStatus); i...
repos\mall-master\mall-admin\src\main\java\com\macro\mall\controller\SmsHomeRecommendSubjectController.java
2
请完成以下Java代码
public class Content { private String body; private boolean approved; private List<String> tags; @JsonCreator public Content( @JsonProperty("body") String body, @JsonProperty("approved") boolean approved, @JsonProperty("tags") List<String> tags ) { this.body = b...
} public boolean isApproved() { return approved; } public void setApproved(boolean approved) { this.approved = approved; } public List<String> getTags() { return tags; } public void setTags(List<String> tags) { this.tags = tags; } @Override pu...
repos\Activiti-develop\activiti-examples\activiti-api-basic-full-example-bean\src\main\java\org\activiti\examples\Content.java
1
请在Spring Boot框架中完成以下Java代码
public void handleEvent(@NonNull final ForecastCreatedEvent event) { final Forecast forecast = event.getForecast(); final CandidateBuilder candidateBuilder = Candidate.builderForEventDescriptor(event.getEventDescriptor()) //.status(EventUtil.getCandidateStatus(forecast.getDocStatus())) .type(CandidateType...
} } private void complementBuilderFromForecastLine( @NonNull final CandidateBuilder candidateBuilder, @NonNull final Forecast forecast, @NonNull final ForecastLine forecastLine) { candidateBuilder .materialDescriptor(forecastLine.getMaterialDescriptor()) .businessCaseDetail(DemandDetail.forForeca...
repos\metasfresh-new_dawn_uat\backend\de.metas.material\dispo-service\src\main\java\de\metas\material\dispo\service\event\handler\foreacast\ForecastCreatedHandler.java
2
请完成以下Java代码
public TypedValue execute(CommandContext commandContext) { ensureNotNull("taskId", taskId); ensureNotNull("variableName", variableName); TaskEntity task = Context .getCommandContext() .getTaskManager() .findTaskById(taskId); ensureNotNull("task " + taskId + " doesn't exist", "task", ...
if (isLocal) { value = task.getVariableLocalTyped(variableName, deserializeValue); } else { value = task.getVariableTyped(variableName, deserializeValue); } return value; } protected void checkGetTaskVariableTyped(TaskEntity task, CommandContext commandContext) { for(CommandChecker che...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cmd\GetTaskVariableCmdTyped.java
1
请完成以下Java代码
public class JMHStreamReduceBenchMark { private final List<User> userList = createUsers(); public static void main(String[] args) throws RunnerException { Options options = new OptionsBuilder() .include(JMHStreamReduceBenchMark.class.getSimpleName()).threads(1) ...
@Benchmark public Integer executeReduceOnParallelizedStream() { return this.userList .parallelStream() .reduce(0, (partialAgeResult, user) -> partialAgeResult + user.getAge(), Integer::sum); } @Benchmark public Integer executeReduceOnSequentialStream() { ...
repos\tutorials-master\core-java-modules\core-java-streams-7\src\main\java\com\baeldung\streams\reduce\benchmarks\JMHStreamReduceBenchMark.java
1
请完成以下Java代码
public class AppHandler implements Handler { private static final Logger LOGGER = Logger.getLogger(AppHandler.class.getSimpleName()); private GraphQL graphql; public AppHandler() throws Exception { GraphQLSchema schema = SchemaParser.newParser() .resolvers(new Query(), new ProductResolv...
.then(payload -> { ExecutionResult executionResult = graphql.execute(payload.get(SchemaUtils.QUERY) .toString(), null, this, Collections.emptyMap()); Map<String, Object> result = new LinkedHashMap<>(); if (executionResult.getErrors() ...
repos\tutorials-master\graphql-modules\graphql-java\src\main\java\com\baeldung\graphqlreturnmap\AppHandler.java
1
请完成以下Java代码
public int getM_AttributeSetInstance_ID() { return get_ValueAsInt(COLUMNNAME_M_AttributeSetInstance_ID); } @Override public void setM_Product_ID (final int M_Product_ID) { if (M_Product_ID < 1) set_ValueNoCheck (COLUMNNAME_M_Product_ID, null); else set_ValueNoCheck (COLUMNNAME_M_Product_ID, M_Produ...
@Override public org.eevolution.model.I_PP_Product_BOMLine getPP_Product_BOMLine() { return get_ValueAsPO(COLUMNNAME_PP_Product_BOMLine_ID, org.eevolution.model.I_PP_Product_BOMLine.class); } @Override public void setPP_Product_BOMLine(final org.eevolution.model.I_PP_Product_BOMLine PP_Product_BOMLine) { set...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\eevolution\model\X_PP_OrderLine_Candidate.java
1
请完成以下Java代码
public class OrdersAggregator extends MapReduceAggregator<OrderHeaderAggregation, PurchaseCandidate> { public static final OrdersAggregator newInstance(final IOrdersCollector collector) { return new OrdersAggregator(collector); } private final IOrdersCollector collector; private OrdersAggregator(final IOrdersC...
@Override public String toString() { return ObjectUtils.toString(this); } @Override protected OrderHeaderAggregation createGroup(final Object itemHashKey, final PurchaseCandidate candidate) { return new OrderHeaderAggregation(); } @Override protected void closeGroup(final OrderHeaderAggregation orderHead...
repos\metasfresh-new_dawn_uat\backend\de.metas.procurement.base\src\main\java\de\metas\procurement\base\order\impl\OrdersAggregator.java
1
请完成以下Java代码
private void changeLane(final int boardId, final int cardId, final int newLaneId) { final int countUpdate = Services.get(IQueryBL.class) .createQueryBuilder(I_WEBUI_Board_RecordAssignment.class) .addEqualsFilter(I_WEBUI_Board_RecordAssignment.COLUMN_WEBUI_Board_ID, boardId) .addEqualsFilter(I_WEBUI_Board...
public void addCardIdAtPosition(final int cardId, final int position) { Preconditions.checkArgument(cardId > 0, "cardId > 0"); if (position < 0) { cardIds.remove((Object)cardId); cardIds.add(cardId); } else if (position == Integer.MAX_VALUE || position > cardIds.size() - 1) { cardIds.re...
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\board\BoardDescriptorRepository.java
1
请在Spring Boot框架中完成以下Java代码
public String getGlobalAcquireLockPrefix() { return globalAcquireLockPrefix; } public void setGlobalAcquireLockPrefix(String globalAcquireLockPrefix) { this.globalAcquireLockPrefix = globalAcquireLockPrefix; } public Duration getAsyncJobsGlobalLockWaitTime() { return asyncJobsG...
public Duration getTimerLockForceAcquireAfter() { return timerLockForceAcquireAfter; } public void setTimerLockForceAcquireAfter(Duration timerLockForceAcquireAfter) { this.timerLockForceAcquireAfter = timerLockForceAcquireAfter; } public Duration getResetExpiredJobsInterval() { ...
repos\flowable-engine-main\modules\flowable-job-service\src\main\java\org\flowable\job\service\impl\asyncexecutor\AsyncJobExecutorConfiguration.java
2
请在Spring Boot框架中完成以下Java代码
public class UserController { private Map<Long, User> userMap = new HashMap<>(); @GetMapping("/v1/users/{userId}") public Mono<ResponseEntity<User>> getV1UserById(@PathVariable Long userId) { return Mono.fromCallable(() -> { User user = userMap.get(userId); if (user == null...
User user = userMap.get(userId); if (user == null) { CustomErrorResponse customErrorResponse = CustomErrorResponse .builder() .traceId(UUID.randomUUID().toString()) .timestamp(OffsetDateTime.now().now()) .status(HttpStat...
repos\tutorials-master\spring-reactive-modules\spring-reactive-exceptions\src\main\java\com\baeldung\spring\reactive\customexception\controller\UserController.java
2
请完成以下Java代码
public Optional<BPartnerId> getBPartnerId(@NonNull final OrderAndLineId orderLineId) { final I_C_OrderLine orderLine = orderDAO.getOrderLineById(orderLineId); return BPartnerId.optionalOfRepoId(orderLine.getC_BPartner_ID()); } @Override public void setTax(@NonNull final org.compiere.model.I_C_OrderLine orderL...
isTaxExempt = null; } final Tax tax = taxDAO.getBy(TaxQuery.builder() .fromCountryId(countryFromId) .orgId(OrgId.ofRepoId(orderLine.getAD_Org_ID())) .bPartnerLocationId(bpLocationId) .warehouseId(warehouseId) .dateOfInterest(taxDate) .taxCategoryId(taxCategoryId) .soTrx(SOTrx.ofBoolean(...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\de\metas\order\impl\OrderLineBL.java
1
请在Spring Boot框架中完成以下Java代码
public void setParametersConsumer(Consumer<LogoutRequestParameters> parametersConsumer) { Assert.notNull(parametersConsumer, "parametersConsumer cannot be null"); this.delegate .setParametersConsumer((parameters) -> parametersConsumer.accept(new LogoutRequestParameters(parameters))); } /** * Use this {@link...
public LogoutRequestParameters(HttpServletRequest request, RelyingPartyRegistration registration, Authentication authentication, LogoutRequest logoutRequest) { this.request = request; this.registration = registration; this.authentication = authentication; this.logoutRequest = logoutRequest; } Logou...
repos\spring-security-main\saml2\saml2-service-provider\src\opensaml5Main\java\org\springframework\security\saml2\provider\service\web\authentication\logout\OpenSaml5LogoutRequestResolver.java
2
请完成以下Java代码
public class PartOfSpeechTagDictionary { /** * 词性映射表 */ public static Map<String, String> translator = new TreeMap<String, String>(); static { load(HanLP.Config.PartOfSpeechTagDictionary); } public static void load(String path) { IOUtil.LineIterator iterator = new...
if (args.length < 3) continue; translator.put(args[1], args[2]); } } /** * 翻译词性 * * @param tag * @return */ public static String translate(String tag) { String cn = translator.get(tag); if (cn == null) return tag; return cn; } }
repos\springboot-demo-master\hanlp\src\main\java\demo\hankcs\hanlp\dictionary\other\PartOfSpeechTagDictionary.java
1
请完成以下Java代码
public PMMContractBuilder addQtyPlanned(final Date date, final BigDecimal qtyPlannedToAdd) { assertNotProcessed(); if (qtyPlannedToAdd == null || qtyPlannedToAdd.signum() == 0) { return this; } if (qtyPlannedToAdd.signum() < 0) { logger.warn("Skip adding negative QtyPlanned={} for {}", qtyPlannedTo...
@Override public String toString() { return MoreObjects.toStringHelper(this) .add("day", day) .add("qtyPlanned", qtyPlanned) .add("qtyPlannedAllocated", qtyPlannedAllocated) .toString(); } public Date getDay() { return day; } public void addQtyPlanned(final BigDecimal qtyPlanne...
repos\metasfresh-new_dawn_uat\backend\de.metas.procurement.base\src\main\java\de\metas\procurement\base\PMMContractBuilder.java
1
请完成以下Java代码
public Optional<Account> getProductCategoryAccount( final @NonNull AcctSchemaId acctSchemaId, final @NonNull ProductCategoryId productCategoryId, final @NonNull ProductAcctType acctType) { if (extension != null) { final Optional<Account> account = extension.getProductCategoryAccount(acctSchemaId, produ...
// // Product Revenue: check/use the override defined on tax level if (acctType == ProductAcctType.P_Revenue_Acct && taxId != null) { final Account productRevenueAcct = taxAccountsRepository.getAccounts(taxId, acctSchemaId) .getT_Revenue_Acct() .orElse(null); if (productRevenueAcct != null) { ...
repos\metasfresh-new_dawn_uat\backend\de.metas.acct.base\src\main\java\de\metas\acct\accounts\AccountProvider.java
1
请在Spring Boot框架中完成以下Java代码
public class BookstoreService { private final BookRepository bookRepository; private final AuthorRepository authorRepository; public BookstoreService(BookRepository bookRepository, AuthorRepository authorRepository) { this.bookRepository = bookRepository; this.authorRepository = authorRepo...
jnb1.setAuthor(jn); authorRepository.save(at); authorRepository.save(jn); bookRepository.save(atb1); bookRepository.save(atb2); bookRepository.save(jnb1); } @Transactional(readOnly = true) public void fetchBookWithAuthor() { Book book = bookRepository.findB...
repos\Hibernate-SpringBoot-master\HibernateSpringBootReferenceNaturalId\src\main\java\com\bookstore\service\BookstoreService.java
2
请完成以下Java代码
public boolean hasActivationRule() { return StringUtils.isNotEmpty(activateCondition); } public boolean hasIgnoreRule() { return StringUtils.isNotEmpty(ignoreCondition); } public boolean hasDefaultRule() { return StringUtils.isNotEmpty(defaultCondition); } public boolean...
public String getIgnoreCondition() { return ignoreCondition; } public void setIgnoreCondition(String ignoreCondition) { this.ignoreCondition = ignoreCondition; } @Override public String toString() { return "ReactivationRule{} " + super.toString(); } @Override pu...
repos\flowable-engine-main\modules\flowable-cmmn-model\src\main\java\org\flowable\cmmn\model\ReactivationRule.java
1
请在Spring Boot框架中完成以下Java代码
public class EmptyCollectionType implements VariableType { public static final String TYPE_NAME = "emptyCollection"; private static final String SET = "set"; private static final String LIST = "list"; private static final Class<?> EMPTY_LIST_CLASS = Collections.emptyList().getClass(); private stat...
public void setValue(Object value, ValueFields valueFields) { if (EMPTY_LIST_CLASS.isInstance(value)) { valueFields.setTextValue("list"); } else { valueFields.setTextValue("set"); } } @Override public Object getValue(ValueFields valueFields) { String ...
repos\flowable-engine-main\modules\flowable-variable-service\src\main\java\org\flowable\variable\service\impl\types\EmptyCollectionType.java
2
请在Spring Boot框架中完成以下Java代码
public class JwtMappingProperties { private String authoritiesPrefix; private String authoritiesClaimName; private String principalClaimName; private Map<String,String> scopes; public String getAuthoritiesClaimName() { return authoritiesClaimName; } public void setAuthoritiesC...
} public void setPrincipalClaimName(String principalClaimName) { this.principalClaimName = principalClaimName; } public Map<String,String> getScopes() { return scopes; } public void setScopes(Map<String,String> scopes) { this.scopes = scopes; } }
repos\tutorials-master\spring-security-modules\spring-security-oidc\src\main\java\com\baeldung\openid\oidc\jwtauthorities\config\JwtMappingProperties.java
2
请完成以下Java代码
public void deleteChildEntity(CommandContext commandContext, DelegatePlanItemInstance delegatePlanItemInstance, boolean cascade) { if (ReferenceTypes.PLAN_ITEM_CHILD_PROCESS.equals(delegatePlanItemInstance.getReferenceType())) { delegatePlanItemInstance.setState(PlanItemInstanceState.TERMINATED); //...
Object variableValue = null; if (StringUtils.isNotEmpty(outParameter.getSourceExpression())) { variableValue = processInstanceService.resolveExpression(planItemInstance.getReferenceId(), outParameter.getSourceExpression()); } else if (StringUtils.isNotEmpty(outParameter.getSourc...
repos\flowable-engine-main\modules\flowable-cmmn-engine\src\main\java\org\flowable\cmmn\engine\impl\behavior\impl\ProcessTaskActivityBehavior.java
1
请完成以下Java代码
public String getProfilePictureUrl() { return this.profilePictureUrl; } public User getUser() { return this.user; } public void setId(Long id) { this.id = id; } public void setBiography(String biography) { this.biography = biography; } public void setW...
public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } Profile profile = (Profile) o; return Objects.equals(id, profile.id); } @Override public int hashCode() ...
repos\tutorials-master\persistence-modules\spring-boot-persistence-4\src\main\java\com\baeldung\listvsset\eager\list\fulldomain\Profile.java
1
请完成以下Java代码
public class SPKIDataType { @XmlElementRef(name = "SPKISexp", namespace = "http://www.w3.org/2000/09/xmldsig#", type = JAXBElement.class) @XmlAnyElement(lax = true) protected List<Object> spkiSexpAndAny; /** * Gets the value of the spkiSexpAndAny property. * * <p> * This accessor ...
* Objects of the following type(s) are allowed in the list * {@link JAXBElement }{@code <}{@link byte[]}{@code >} * {@link Element } * {@link Object } * * */ public List<Object> getSPKISexpAndAny() { if (spkiSexpAndAny == null) { spkiSexpAndAny = new ArrayList<Obj...
repos\metasfresh-new_dawn_uat\backend\vertical-healthcare_ch\forum_datenaustausch_ch.invoice_440_request\src\main\java-xjc\de\metas\vertical\healthcare_ch\forum_datenaustausch_ch\invoice_440\request\SPKIDataType.java
1
请完成以下Java代码
public void setAuthenticatedUserId(String authenticatedUserId) { Authentication.setAuthenticatedUserId(authenticatedUserId); } @Override public String getUserInfo(String userId, String key) { return getIdmIdentityService().getUserInfo(userId, key); } @Override public List<Strin...
getIdmIdentityService().setUserInfo(userId, key, value); } @Override public void deleteUserInfo(String userId, String key) { getIdmIdentityService().deleteUserInfo(userId, key); } protected IdmIdentityService getIdmIdentityService() { IdmIdentityService idmIdentityService = Eng...
repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\IdentityServiceImpl.java
1
请完成以下Java代码
public static boolean isExpression(String text) { if (text == null) { return false; } text = text.trim(); return text.startsWith("${") || text.startsWith("#{"); } /** * Splits a String by an expression. * * @param text the text to split * @param regex the regex to split by * @r...
StringBuilder stringBuilder = new StringBuilder(); for (int i=0; i < parts.length; i++) { if (i > 0) { stringBuilder.append(delimiter); } stringBuilder.append(parts[i]); } return stringBuilder.toString(); } /** * Returns either the passed in String, or if the String is <cod...
repos\camunda-bpm-platform-master\commons\utils\src\main\java\org\camunda\commons\utils\StringUtil.java
1
请完成以下Java代码
private Entry<String, List<String>> getHeaderEntry(int n) { Iterator<Entry<String, List<String>>> iterator = getHeaderFields().entrySet().iterator(); Entry<String, List<String>> entry = null; for (int i = 0; i < n; i++) { entry = (!iterator.hasNext()) ? null : iterator.next(); } return entry; } @Overrid...
connect(); return new ConnectionInputStream(this.resources.getInputStream()); } @Override public void connect() throws IOException { if (this.connected) { return; } this.resources.connect(); this.connected = true; } /** * Connection {@link InputStream}. */ class ConnectionInputStream extends Fi...
repos\spring-boot-4.0.1\loader\spring-boot-loader\src\main\java\org\springframework\boot\loader\net\protocol\nested\NestedUrlConnection.java
1
请完成以下Java代码
public ExecutionEntity getProcessInstance() { if ((processInstance == null) && (processInstanceId != null)) { this.processInstance = Context.getCommandContext().getExecutionEntityManager().findById(processInstanceId); } return processInstance; } public void setProcessInstanc...
sb.append(", userId=").append(userId); } if (groupId != null) { sb.append(", groupId=").append(groupId); } if (taskId != null) { sb.append(", taskId=").append(taskId); } if (processInstanceId != null) { sb.append(", processInstanceId=")...
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\persistence\entity\IdentityLinkEntityImpl.java
1
请完成以下Java代码
public class SetExternalTaskRetriesCmd extends ExternalTaskCmd { protected int retries; protected boolean writeUserOperationLog; public SetExternalTaskRetriesCmd(String externalTaskId, int retries, boolean writeUserOperationLog) { super(externalTaskId); this.retries = retries; this.writeUserOperatio...
@Override protected String getUserOperationLogOperationType() { if (writeUserOperationLog) { return UserOperationLogEntry.OPERATION_TYPE_SET_EXTERNAL_TASK_RETRIES; } return super.getUserOperationLogOperationType(); } @Override protected List<PropertyChange> getUserOperationLogPropertyChange...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cmd\SetExternalTaskRetriesCmd.java
1
请完成以下Java代码
public CaseSentryPartQueryImpl satisfied() { this.satisfied = true; return this; } // order by /////////////////////////////////////////// public CaseSentryPartQueryImpl orderByCaseSentryId() { orderBy(CaseSentryPartQueryProperty.CASE_SENTRY_PART_ID); return this; } public CaseSentryPartQue...
return caseExecutionId; } public String getSentryId() { return sentryId; } public String getType() { return type; } public String getSourceCaseExecutionId() { return sourceCaseExecutionId; } public String getStandardEvent() { return standardEvent; } public String getVariableEven...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cmmn\entity\runtime\CaseSentryPartQueryImpl.java
1
请完成以下Java代码
public BalanceType5Choice getCdOrPrtry() { return cdOrPrtry; } /** * Sets the value of the cdOrPrtry property. * * @param value * allowed object is * {@link BalanceType5Choice } * */ public void setCdOrPrtry(BalanceType5Choice value) { this.c...
* {@link BalanceSubType1Choice } * */ public BalanceSubType1Choice getSubTp() { return subTp; } /** * Sets the value of the subTp property. * * @param value * allowed object is * {@link BalanceSubType1Choice } * */ public void ...
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\BalanceType12.java
1
请完成以下Java代码
public RoleId getFirstRoleId() { getRecipients(false); for (int i = 0; i < m_recipients.length; i++) { if (m_recipients[i].getAD_Role_ID() >= 0) { return RoleId.ofRepoId(m_recipients[i].getAD_Role_ID()); } } return null; } // getForstAD_Role_ID /** * Get First User Role if exist * @retu...
{ final Set<UserId> allRoleUserIds = Services.get(IRoleDAO.class).retrieveUserIdsForRoleId(roleId); users.addAll(allRoleUserIds); } } return users; } /** * String Representation * @return info */ @Override public String toString () { StringBuffer sb = new StringBuffer ("MAlert["); sb.ap...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-legacy\org\compiere\model\MAlert.java
1
请在Spring Boot框架中完成以下Java代码
public class OrderProcessingListeners { private static final Logger logger = LoggerFactory.getLogger(OrderProcessingListeners.class); private final InventoryService inventoryService; private final OrderService orderService; public OrderProcessingListeners(InventoryService inventoryService, OrderServ...
logger.info("Releasing processing thread."); } @SqsListener(value = "${events.queues.order-processing-no-retries-queue}", acknowledgementMode = "${events.acknowledgment.order-processing-no-retries-queue}", id = "no-retries-order-processing-container", messageVisibilitySeconds = "3") public void stockCheckN...
repos\tutorials-master\spring-cloud-modules\spring-cloud-aws-v3\src\main\java\com\baeldung\spring\cloud\aws\sqs\acknowledgement\listener\OrderProcessingListeners.java
2
请完成以下Java代码
public void setField(GridField mField) { m_mField = mField; EditorContextPopupMenu.onGridFieldSet(this); } // setField @Override public GridField getField() { return m_mField; } /** * Action Listener Interface * @param listener listener */ @Override public void addActionListener(ActionListener...
public void propertyChange (PropertyChangeEvent evt) { if (evt.getPropertyName().equals(org.compiere.model.GridField.PROPERTY)) setValue(evt.getNewValue()); // metas: request focus (2009_0027_G131) if (evt.getPropertyName().equals(org.compiere.model.GridField.REQUEST_FOCUS)) requestFocus(); // metas ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java-legacy\org\compiere\grid\ed\VAssignment.java
1
请完成以下Java代码
public void mouseClicked(MouseEvent e) { if (!(e.getSource() instanceof VTable)) { return; } // m_vtable = (VTable)e.getSource(); final int rowIndexView = m_vtable.rowAtPoint(e.getPoint()); final int columnIndexView = m_vtable.columnAtPoint(e.getPoint()); final TableCellRenderer r = m_vtable.get...
return; } } private Component editCellAt(MouseEvent e) { if (m_vtable == null) { return null; } final Point p = e.getPoint(); final boolean canEdit = !m_vtable.isEditing() || m_vtable.getCellEditor().stopCellEditing(); if (canEdit && m_vtable.editCellAt(m_vtable.rowAtPoint(p), m_vtable.columnAtPo...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java\org\compiere\grid\VTableMouseListener.java
1
请完成以下Java代码
public class WebController { private static final int DEFAULT_PORT = 8080; public static final String SLOW_SERVICE_PRODUCTS_ENDPOINT_NAME = "/slow-service-products"; @Setter private int serverPort = DEFAULT_PORT; @Autowired private ProductsFeignClient productsFeignClient; @GetMapping("/...
@GetMapping(value = "/products-non-blocking", produces = MediaType.TEXT_EVENT_STREAM_VALUE) public Flux<Product> getProductsNonBlocking() { log.info("Starting NON-BLOCKING Controller!"); Flux<Product> productFlux = WebClient.create() .get() .uri(getSlowServiceBaseUri() + SLOW_SER...
repos\tutorials-master\spring-reactive-modules\spring-reactive-client\src\main\java\com\baeldung\webclient\WebController.java
1
请完成以下Java代码
public DocumentId getId() { return id; } @Override public AttachmentEntryType getType() { return AttachmentEntryType.Data; } @Override public String getFilename() { final String contentType = getContentType(); final String fileExtension = MimeType.getExtensionByType(contentType); final String name ...
public String getContentType() { return archiveBL.getContentType(archive); } @Override public URI getUrl() { return null; } @Override public Instant getCreated() { return archive.getCreated().toInstant(); } }
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\attachments\DocumentArchiveEntry.java
1
请在Spring Boot框架中完成以下Java代码
public class AccountConfigUtil { private static final Log LOG = LogFactory.getLog(AccountConfigUtil.class); /** * 通过静态代码块读取上传文件的验证格式配置文件,静态代码块只执行一次(单例) */ private static Properties properties = new Properties(); private AccountConfigUtil() { } // 通过类装载器装载进来 static { tr...
LOG.error(e); } } /** * 函数功能说明 :读取配置项 Administrator 2012-12-14 修改者名字 : 修改日期 : 修改内容 : * * @参数: * @return void * @throws */ public static String readConfig(String key) { return (String) properties.get(key); } }
repos\roncoo-pay-master\roncoo-pay-service\src\main\java\com\roncoo\pay\account\utils\AccountConfigUtil.java
2
请完成以下Java代码
public class LogMDC { public static final String LOG_MDC_PROCESSDEFINITION_ID = "mdcProcessDefinitionID"; public static final String LOG_MDC_EXECUTION_ID = "mdcExecutionId"; public static final String LOG_MDC_PROCESSINSTANCE_ID = "mdcProcessInstanceID"; public static final String LOG_MDC_BUSINESS_KEY =...
} if (e.getProcessDefinitionId() != null) { MDC.put(LOG_MDC_PROCESSDEFINITION_ID, e.getProcessDefinitionId()); } if (e.getProcessInstanceId() != null) { MDC.put(LOG_MDC_PROCESSINSTANCE_ID, e.getProcessInstanceId()); } if (e.getProcessInstanceBusinessKey() ...
repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\logging\LogMDC.java
1
请完成以下Java代码
public final boolean isCloseOnCompletion() throws SQLException { return getStatementImpl().isCloseOnCompletion(); } @Override public final String getSql() { return this.vo.getSql(); } protected final String convertSqlAndSet(final String sql) { final String sqlConverted = DB.getDatabase().convertStatemen...
} @Nullable private static Trx getTrx(@NonNull final CStatementVO vo) { final ITrxManager trxManager = Services.get(ITrxManager.class); final String trxName = vo.getTrxName(); if (trxManager.isNull(trxName)) { return (Trx)ITrx.TRX_None; } else { final ITrx trx = trxManager.get(trxName, false); /...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\org\adempiere\sql\impl\AbstractCStatementProxy.java
1
请完成以下Java代码
protected TaskEntityManager getTaskManager() { return getSession(TaskEntityManager.class); } protected IdentityLinkEntityManager getIdentityLinkManager() { return getSession(IdentityLinkEntityManager.class); } protected EventSubscriptionEntityManager getEventSubscriptionManager() { ...
protected HistoricIdentityLinkEntityManager getHistoricIdentityLinkEntityManager() { return getSession(HistoricIdentityLinkEntityManager.class); } protected AttachmentEntityManager getAttachmentManager() { return getSession(AttachmentEntityManager.class); } protected HistoryManager get...
repos\flowable-engine-main\modules\flowable5-engine\src\main\java\org\activiti\engine\impl\persistence\AbstractManager.java
1
请完成以下Java代码
public @Nullable LibraryScope getScope() { return this.scope; } /** * Return the {@linkplain LibraryCoordinates coordinates} of the library. * @return the coordinates */ public @Nullable LibraryCoordinates getCoordinates() { return this.coordinates; } /** * Return if the file cannot be used directly ...
} /** * Return if the library is local (part of the same build) to the application that is * being packaged. * @return if the library is local */ public boolean isLocal() { return this.local; } /** * Return if the library is included in the uber jar. * @return if the library is included */ public...
repos\spring-boot-4.0.1\loader\spring-boot-loader-tools\src\main\java\org\springframework\boot\loader\tools\Library.java
1
请在Spring Boot框架中完成以下Java代码
public String getREFERENCEDATE1() { return referencedate1; } /** * Sets the value of the referencedate1 property. * * @param value * allowed object is * {@link String } * */ public void setREFERENCEDATE1(String value) { this.referencedate1 = ...
} /** * Sets the value of the referencedate2 property. * * @param value * allowed object is * {@link String } * */ public void setREFERENCEDATE2(String value) { this.referencedate2 = value; } }
repos\metasfresh-new_dawn_uat\misc\services\camel\de-metas-camel-edi\src\main\java-xjc_stepcom_desadv\de\metas\edi\esb\jaxb\stepcom\desadv\DREFE1.java
2
请在Spring Boot框架中完成以下Java代码
public class ImageClassificationController { private final ImageClassificationService imageClassificationService; @PostMapping(path = "/analyze") public String predict(@RequestPart("image") MultipartFile image, @RequestParam(defaultValue = "/home/djl-test/models") String modePath...
return ResponseEntity.notFound().build(); } HttpHeaders headers = new HttpHeaders(); headers.add(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename=" + file.getFileName().toString()); headers.add(HttpHeaders.CONTENT_TYPE, MediaType.IMAGE_JPEG_VALUE); try { return...
repos\springboot-demo-master\djl\src\main\java\com\et\controller\ImageClassificationController.java
2
请完成以下Java代码
class ModelCacheSourceModel implements ICacheSourceModel { private final Object model; ModelCacheSourceModel(@NonNull final Object model) { this.model = model; } @Override public String getTableName() { return InterfaceWrapperHelper.getModelTableName(model); } @Override public int getRecordId() { re...
public TableRecordReference getRootRecordReferenceOrNull() { return null; } @Override public Integer getValueAsInt(final String columnName, final Integer defaultValue) { final Object valueObj = InterfaceWrapperHelper.getValueOrNull(model, columnName); return NumberUtils.asInteger(valueObj, defaultValue); }...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\cache\model\ModelCacheSourceModel.java
1
请完成以下Java代码
public static void processOutParameters(List<IOParameter> outParameters, VariableContainer sourceContainer, BiConsumer<String, Object> targetVariableConsumer, BiConsumer<String, Object> targetTransientVariableConsumer, ExpressionManager expressionManager) { processParameters(outParameters, sourceCon...
if (value != null) { value = JsonUtil.deepCopyIfJson(value); } String variableName = null; if (StringUtils.isNotEmpty(parameter.getTargetExpression())) { Expression expression = expressionManager.createExpression(parameter.getTargetExpression()); ...
repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\util\IOParameterUtil.java
1
请完成以下Java代码
private ImmutableMap<JsonExternalReferenceLookupItem, ExternalReferenceQuery> extractRepoQueries( @NonNull final ImmutableSet<JsonExternalReferenceLookupItem> items, @NonNull final OrgId orgId, @NonNull final ExternalSystem externalSystem) { final ImmutableMap.Builder<JsonExternalReferenceLookupItem, Extern...
final ExternalReference externalReference = externalReferences.get(lookupItem2QueryEntry.getValue()).orElse(null); final JsonExternalReferenceItem responseItem; if (externalReference == null) { responseItem = JsonExternalReferenceItem.of(lookupItem); } else { responseItem = JsonExternalRefer...
repos\metasfresh-new_dawn_uat\backend\de.metas.externalreference\src\main\java\de\metas\externalreference\rest\v2\ExternalReferenceRestControllerService.java
1
请完成以下Java代码
public void validateLine(final I_GL_DistributionLine line) { if (line.getLine() == 0) { final I_GL_Distribution glDistribution = line.getGL_Distribution(); final int lastLineNo = glDistributionDAO.retrieveLastLineNo(glDistribution); final int lineNo = lastLineNo + 10; line.setLine(lineNo); } // Re...
// Account Overwrite cannot be 0 if (line.isOverwriteAcct() && line.getAccount_ID() <= 0) { throw new FillMandatoryException(I_GL_DistributionLine.COLUMNNAME_Account_ID); } // Org Overwrite cannot be 0 if (line.isOverwriteOrg() && line.getOrg_ID() <= 0) { throw new FillMandatoryException(I_GL_Distribu...
repos\metasfresh-new_dawn_uat\backend\de.metas.acct.base\src\main\java\de\metas\acct\interceptor\GL_DistributionLine.java
1
请完成以下Java代码
public long findDeploymentCountByQueryCriteria(DmnDeploymentQueryImpl deploymentQuery) { return dataManager.findDeploymentCountByQueryCriteria(deploymentQuery); } @Override public List<DmnDeployment> findDeploymentsByQueryCriteria(DmnDeploymentQueryImpl deploymentQuery) { return dataManager...
public long findDeploymentCountByNativeQuery(Map<String, Object> parameterMap) { return dataManager.findDeploymentCountByNativeQuery(parameterMap); } protected DmnResourceEntityManager getResourceEntityManager() { return engineConfiguration.getResourceEntityManager(); } protected Histo...
repos\flowable-engine-main\modules\flowable-dmn-engine\src\main\java\org\flowable\dmn\engine\impl\persistence\entity\DmnDeploymentEntityManagerImpl.java
1
请完成以下Spring Boot application配置
server: port: 8097 servlet: session: timeout: 30 spring: application: name: roncoo-pay-app-reconciliation logging: config: classpath:logbac
k.xml mybatis: mapper-locations: classpath*:mybatis/mapper/**/*.xml
repos\roncoo-pay-master\roncoo-pay-app-reconciliation\src\main\resources\application.yml
2
请完成以下Java代码
public void postInit(ProcessEngineConfigurationImpl processEngineConfiguration) { for (ProcessEnginePlugin plugin : plugins) { plugin.postInit(processEngineConfiguration); } } @Override public void postProcessEngineBuild(ProcessEngine processEngine) { for (ProcessEnginePlugin plugin : plugins) ...
return plugins; } @Override public String toString() { return this.getClass().getSimpleName() + plugins; } private static List<ProcessEnginePlugin> toList(ProcessEnginePlugin plugin, ProcessEnginePlugin... additionalPlugins) { final List<ProcessEnginePlugin> plugins = new ArrayList<ProcessEnginePlu...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cfg\CompositeProcessEnginePlugin.java
1
请完成以下Java代码
private ProcessPreconditionsResolution checkSingleLineSelectedWhichIsForeignCurrency(@NonNull final IProcessPreconditionsContext context) { final Set<TableRecordReference> bankStatemementLineRefs = context.getSelectedIncludedRecords(); if (bankStatemementLineRefs.size() != 1) { return ProcessPreconditionsReso...
{ return getSingleSelectedBankStatementLine().getCurrencyRate(); } else { return IProcessDefaultParametersProvider.DEFAULT_VALUE_NOTAVAILABLE; } } @Override protected String doIt() { if (currencyRate == null || currencyRate.signum() == 0) { throw new FillMandatoryException("CurrencyRate"); }...
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\banking\process\C_BankStatement_ChangeCurrencyRate.java
1
请完成以下Java代码
private void addHeaderLine(final String labelText, final Component field) { if (labelText != null) { final Properties ctx = Env.getCtx(); final CLabel label = new CLabel(Services.get(IMsgBL.class).translate(ctx, labelText)); headerPanel.add(label, new GridBagConstraints(0, m_headerLine, 1, 1, 0.0, 0....
confirmPanel.getOKButton().setEnabled(false); // if (m_isPrintOnOK) { m_isPrinted = fMessage.print(); } } finally { confirmPanel.getOKButton().setEnabled(true); setCursor(Cursor.getDefaultCursor()); } // m_isPrinted = true; m_isPressedOK = true; dispose(); } else if...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java\org\compiere\apps\LetterDialog.java
1
请完成以下Java代码
public String getResourceName() { return resourceName; } public String getResourceNameLike() { return resourceNameLike; } public SuspensionState getSuspensionState() { return suspensionState; } public void setSuspensionState(SuspensionState suspensionState) { t...
public String getEventSubscriptionName() { return eventSubscriptionName; } public String getEventSubscriptionType() { return eventSubscriptionType; } public ProcessDefinitionQueryImpl startableByUser(String userId) { if (userId == null) { throw new ActivitiIllegalAr...
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\ProcessDefinitionQueryImpl.java
1
请完成以下Java代码
private int getPort(UriComponents uriComponents) { int port = uriComponents.getPort(); if (port != -1) { return port; } if ("https".equalsIgnoreCase(uriComponents.getScheme())) { return 443; } return 80; } @Override public @Nullable HttpServletRequest getMatchingRequest(HttpServletRequest request,...
String currentUrl = UrlUtils.buildFullRequestUrl(request); return savedRequest.getRedirectUrl().equals(currentUrl); } /** * Allows selective use of saved requests for a subset of requests. By default any * request will be cached by the {@code saveRequest} method. * <p> * If set, only matching requests will...
repos\spring-security-main\web\src\main\java\org\springframework\security\web\savedrequest\CookieRequestCache.java
1
请完成以下Java代码
public Integer getSort() { return sort; } public void setSort(Integer sort) { this.sort = sort; } public Integer getFilterType() { return filterType; } public void setFilterType(Integer filterType) { this.filterType = filterType; } public Integer getSe...
public void setType(Integer type) { this.type = type; } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append(getClass().getSimpleName()); sb.append(" ["); sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id)...
repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\PmsProductAttribute.java
1
请完成以下Java代码
public static CRFModel loadTxt(String path) { return loadTxt(path, new CRFModel(new DoubleArrayTrie<FeatureFunction>())); } /** * 加载CRF++模型<br> * 如果存在缓存的话,优先读取缓存,否则读取txt,并且建立缓存 * * @param path txt的路径,即使不存在.txt,只存在.bin,也应传入txt的路径,方法内部会自动加.bin后缀 * @return */ public s...
ByteArray byteArray = ByteArray.createByteArray(path); if (byteArray == null) return null; CRFModel model = new CRFModel(); if (model.load(byteArray)) return model; return null; } /** * 获取某个tag的ID * * @param tag * @return */ public Integer getTagId(S...
repos\springboot-demo-master\hanlp\src\main\java\demo\hankcs\hanlp\model\crf\CRFModel.java
1
请在Spring Boot框架中完成以下Java代码
public String getProcessDefinitionKeyLikeIgnoreCase() { return processDefinitionKeyLikeIgnoreCase; } public String getLocale() { return locale; } public boolean isOrActive() { return orActive; } public boolean isUnassigned() { return unassigned; } publ...
cachedCandidateGroups = null; return super.listPage(firstResult, maxResults); } @Override public long count() { cachedCandidateGroups = null; return super.count(); } public List<List<String>> getSafeCandidateGroups() { return safeCandidateGroups; } public v...
repos\flowable-engine-main\modules\flowable-task-service\src\main\java\org\flowable\task\service\impl\TaskQueryImpl.java
2
请完成以下Java代码
private static List<DocumentPath> createSelectedIncludedDocumentPaths(final WindowId windowId, final String documentIdStr, final JSONSelectedIncludedTab selectedTab) { if (windowId == null || Check.isEmpty(documentIdStr, true) || selectedTab == null) { return ImmutableList.of(); } final DocumentId document...
@JsonAutoDetect(fieldVisibility = Visibility.ANY, getterVisibility = Visibility.NONE, isGetterVisibility = Visibility.NONE, setterVisibility = Visibility.NONE) @Data public static final class JSONSelectedIncludedTab { @JsonProperty("tabId") private final String tabId; @JsonProperty("rowIds") private final Li...
repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\process\json\JSONCreateProcessInstanceRequest.java
1
请完成以下Java代码
public class MultipartConfigFactory { private @Nullable String location; private @Nullable DataSize maxFileSize; private @Nullable DataSize maxRequestSize; private @Nullable DataSize fileSizeThreshold; /** * Sets the directory location where files will be stored. * @param location the location */ publi...
/** * Create a new {@link MultipartConfigElement} instance. * @return the multipart config element */ public MultipartConfigElement createMultipartConfig() { long maxFileSizeBytes = convertToBytes(this.maxFileSize, -1); long maxRequestSizeBytes = convertToBytes(this.maxRequestSize, -1); long fileSizeThresh...
repos\spring-boot-4.0.1\module\spring-boot-servlet\src\main\java\org\springframework\boot\servlet\MultipartConfigFactory.java
1
请在Spring Boot框架中完成以下Java代码
public class BookstoreService { private final AuthorRepository authorRepository; public BookstoreService(AuthorRepository authorRepository) { this.authorRepository = authorRepository; } @Transactional public void insertAuthorWithBooks() { Author jn = new Author(); ...
Book book = new Book(); book.setIsbn("004-JN"); book.setTitle("History Details"); author.addBook(book); // use addBook() helper authorRepository.save(author); } @Transactional public void deleteLastBook() { Author author = authorRepository.fetchByName("Joana Nimar...
repos\Hibernate-SpringBoot-master\HibernateSpringBootOneToManyUnidirectional\src\main\java\com\bookstore\service\BookstoreService.java
2
请完成以下Java代码
public void setLoginDate (final @Nullable java.sql.Timestamp LoginDate) { set_Value (COLUMNNAME_LoginDate, LoginDate); } @Override public java.sql.Timestamp getLoginDate() { return get_ValueAsTimestamp(COLUMNNAME_LoginDate); } @Override public void setLoginUsername (final @Nullable java.lang.String Login...
@Override public void setRemote_Host (final @Nullable java.lang.String Remote_Host) { set_ValueNoCheck (COLUMNNAME_Remote_Host, Remote_Host); } @Override public java.lang.String getRemote_Host() { return get_ValueAsString(COLUMNNAME_Remote_Host); } @Override public void setWebSession (final @Nullable ja...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_AD_Session.java
1
请完成以下Java代码
public String getCategory() { throw new UnsupportedOperationException(); } @Override public CamundaFormDefinitionEntity getPreviousDefinition() { throw new UnsupportedOperationException(); } @Override public void setCategory(String category) { throw new UnsupportedOperationException(); } ...
throw new UnsupportedOperationException("history time to live not supported for Camunda Forms"); } @Override public Object getPersistentState() { // properties of this entity are immutable return CamundaFormDefinitionEntity.class; } @Override public void updateModifiableFieldsFromEntity(CamundaFor...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\persistence\entity\CamundaFormDefinitionEntity.java
1
请在Spring Boot框架中完成以下Java代码
public class QueryStringController { @GetMapping("/api/byGetQueryString") public String byGetQueryString(HttpServletRequest request) { return request.getQueryString(); } @GetMapping("/api/byGetParameter") public String byGetParameter(HttpServletRequest request) { String username = ...
@GetMapping("/api/byParameterName") public UserDto byParameterName(String username, String[] roles) { UserDto userDto = new UserDto(); userDto.setUsername(username); userDto.setRoles(Arrays.asList(roles)); return userDto; } @GetMapping("/api/byAnnoRequestParam") public U...
repos\tutorials-master\spring-web-modules\spring-mvc-basics-6\src\main\java\com\baeldung\requestparam\QueryStringController.java
2
请完成以下Java代码
private void throwExceptionIfEmptyResult( final List<PurchaseItem> remotePurchaseItems, final Collection<PurchaseCandidate> purchaseCandidatesWithVendorId, final BPartnerId vendorId) { if (remotePurchaseItems.isEmpty()) { final I_C_BPartner vendor = Services.get(IBPartnerDAO.class).getById(vendorId); ...
MSG_ERROR_WHILE_PLACING_REMOTE_PURCHASE_ORDER, vendor.getValue(), vendor.getName()) .appendParametersToMessage() .setParameter("purchaseCandidatesWithVendorId", purchaseCandidatesWithVendorId) .setParameter("purchaseErrorItems", purchaseErrorItems); } private void logAndRethrow( final Throwable th...
repos\metasfresh-new_dawn_uat\backend\de.metas.purchasecandidate.base\src\main\java\de\metas\purchasecandidate\purchaseordercreation\PurchaseCandidateToOrderWorkflow.java
1
请在Spring Boot框架中完成以下Java代码
public SysThirdAccount bindThirdAppAccountByUserId(SysThirdAccount sysThirdAccount) { String thirdUserUuid = sysThirdAccount.getThirdUserUuid(); String thirdType = sysThirdAccount.getThirdType(); //获取当前登录用户 LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); ...
@Override public SysThirdAccount getOneByUuidAndThirdType(String unionid, String thirdType,Integer tenantId,String thirdUserId) { LambdaQueryWrapper<SysThirdAccount> queryWrapper = new LambdaQueryWrapper<>(); queryWrapper.eq(SysThirdAccount::getThirdType, thirdType); // 代码逻辑说明: 如果第三方用户id为空那么...
repos\JeecgBoot-main\jeecg-boot\jeecg-module-system\jeecg-system-biz\src\main\java\org\jeecg\modules\system\service\impl\SysThirdAccountServiceImpl.java
2
请完成以下Java代码
public List<IdentityLink> execute(CommandContext commandContext) { TaskEntity task = commandContext.getTaskEntityManager().findById(taskId); List<IdentityLink> identityLinks = (List) task.getIdentityLinks(); // assignee is not part of identity links in the db. // so if there is one, we...
identityLink.setType(IdentityLinkType.ASSIGNEE); identityLink.setTaskId(task.getId()); identityLinks.add(identityLink); } if (task.getOwner() != null) { IdentityLinkEntity identityLink = commandContext.getIdentityLinkEntityManager().create(); identityLink....
repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\cmd\GetIdentityLinksForTaskCmd.java
1
请完成以下Java代码
public void setReference (java.lang.String Reference) { set_Value (COLUMNNAME_Reference, Reference); } /** Get Referenz. @return Reference for this record */ @Override public java.lang.String getReference () { return (java.lang.String)get_Value(COLUMNNAME_Reference); } /** Set Zusammenfassung. @pa...
{ return (java.lang.String)get_Value(COLUMNNAME_Summary); } /** Set Mitteilung. @param TextMsg Text Message */ @Override public void setTextMsg (java.lang.String TextMsg) { set_Value (COLUMNNAME_TextMsg, TextMsg); } /** Get Mitteilung. @return Text Message */ @Override public java.lang.Strin...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_AD_SchedulerLog.java
1
请在Spring Boot框架中完成以下Java代码
public void createInvoicePaySchedules(final I_C_Invoice invoice) { InvoicePayScheduleCreateCommand.builder() .invoicePayScheduleRepository(invoicePayScheduleRepository) .orderPayScheduleService(orderPayScheduleService) .paymentTermService(paymentTermService) .invoiceRecord(invoice) .build() ....
private void validateInvoicesNow(final Set<InvoiceId> invoiceIds) { if (invoiceIds.isEmpty()) {return;} final ImmutableMap<InvoiceId, I_C_Invoice> invoicesById = Maps.uniqueIndex( invoiceBL.getByIds(invoiceIds), invoice -> InvoiceId.ofRepoId(invoice.getC_Invoice_ID()) ); invoicePayScheduleRepository....
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\de\metas\invoice\paymentschedule\service\InvoicePayScheduleService.java
2
请完成以下Java代码
public String getRoleName(final RoleId adRoleId) { if (adRoleId == null) { return "?"; } final Role role = getById(adRoleId); return role.getName(); } @Override // @Cached(cacheName = I_AD_User_Roles.Table_Name + "#by#AD_Role_ID", expireMinutes = 0) // not sure if caching is needed... public Set<Use...
userRole.setAD_Role_ID(adRoleId.getRepoId()); InterfaceWrapperHelper.save(userRole); Services.get(IUserRolePermissionsDAO.class).resetCacheAfterTrxCommit(); } private boolean hasUserRoleAssignment(final UserId adUserId, final RoleId adRoleId) { return Services.get(IQueryBL.class) .createQueryBuilder(I_AD...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\security\impl\RoleDAO.java
1
请完成以下Java代码
public void applyRequestMetadata(final RequestInfo requestInfo, final Executor appExecutor, final MetadataApplier applier) { if (isPrivacyGuaranteed(requestInfo.getSecurityLevel())) { this.callCredentials.applyRequestMetadata(requestInfo, appExecutor, applier); } ...
*/ private static final class IncludeWhenPrivateCallCredentials extends CallCredentials { private final CallCredentials callCredentials; IncludeWhenPrivateCallCredentials(final CallCredentials callCredentials) { this.callCredentials = callCredentials; } @Override ...
repos\grpc-spring-master\grpc-client-spring-boot-starter\src\main\java\net\devh\boot\grpc\client\security\CallCredentialsHelper.java
1
请完成以下Java代码
public boolean isSameFile(Path path, Path path2) throws IOException { return path.equals(path2); } @Override public boolean isHidden(Path path) throws IOException { return false; } @Override public FileStore getFileStore(Path path) throws IOException { NestedPath nestedPath = NestedPath.cast(path); nest...
public <A extends BasicFileAttributes> A readAttributes(Path path, Class<A> type, LinkOption... options) throws IOException { Path jarPath = getJarPath(path); return jarPath.getFileSystem().provider().readAttributes(jarPath, type, options); } @Override public Map<String, Object> readAttributes(Path path, Str...
repos\spring-boot-4.0.1\loader\spring-boot-loader\src\main\java\org\springframework\boot\loader\nio\file\NestedFileSystemProvider.java
1
请完成以下Java代码
public void updateById( @NonNull final PPOrderWeightingRunId runId, @NonNull final Consumer<PPOrderWeightingRun> consumer) { final PPOrderWeightingRunLoaderAndSaver loaderAndSaver = new PPOrderWeightingRunLoaderAndSaver(); loaderAndSaver.updateById(runId, consumer); } public void deleteChecks(final PPOrde...
@NonNull final SeqNo lineNo, @NonNull final Quantity weight, @NonNull final OrgId orgId) { final I_PP_Order_Weighting_RunCheck record = InterfaceWrapperHelper.newInstance(I_PP_Order_Weighting_RunCheck.class); record.setAD_Org_ID(orgId.getRepoId()); record.setPP_Order_Weighting_Run_ID(weightingRunId.getRepo...
repos\metasfresh-new_dawn_uat\backend\de.metas.manufacturing\src\main\java\de\metas\manufacturing\order\weighting\run\PPOrderWeightingRunRepository.java
1
请完成以下Java代码
protected void instantiate(ExecutionEntity ancestorScopeExecution, List<PvmActivity> parentFlowScopes, CoreModelElement targetElement) { if (PvmTransition.class.isAssignableFrom(targetElement.getClass())) { ancestorScopeExecution.executeActivities(parentFlowScopes, null, (PvmTransition) targetElement, variabl...
variablesLocal, skipCustomListeners, skipIoMappings); } else { throw new ProcessEngineException("Cannot instantiate element " + targetElement); } } protected abstract ScopeImpl getTargetFlowScope(ProcessDefinitionImpl processDefinition); protected abstract CoreModelElement getTargetElement(Pr...
repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\cmd\AbstractInstantiationCmd.java
1
请在Spring Boot框架中完成以下Java代码
public class SumUpPendingTransactionContinuousUpdater implements SumUpTransactionStatusChangedListener { private static final String SYSCONFIG_PollIntervalInSeconds = "de.metas.payment.sumup.pendingTransactionsUpdate.pollIntervalInSeconds"; private static final Duration DEFAULT_PollInterval = Duration.ofSeconds(2); ...
{ logger.debug("Sleeping {}", duration); Thread.sleep(duration.toMillis()); return true; } catch (InterruptedException e) { return false; } } private void bulkUpdatePendingTransactionsNoFail() { try { final BulkUpdateByQueryResult result = sumUpService.bulkUpdatePendingTransactions(false)...
repos\metasfresh-new_dawn_uat\backend\de.metas.payment.sumup\src\main\java\de\metas\payment\sumup\server\SumUpPendingTransactionContinuousUpdater.java
2
请完成以下Java代码
public Byte getCommentStatus() { return commentStatus; } public void setCommentStatus(Byte commentStatus) { this.commentStatus = commentStatus; } public Byte getIsDeleted() { return isDeleted; } public void setIsDeleted(Byte isDeleted) { this.isDeleted = isDele...
@Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append(getClass().getSimpleName()); sb.append(" ["); sb.append("Hash = ").append(hashCode()); sb.append(", commentId=").append(commentId); sb.append(", newsId=").append(newsId); sb...
repos\spring-boot-projects-main\SpringBoot咨询发布系统实战项目源码\springboot-project-news-publish-system\src\main\java\com\site\springboot\core\entity\NewsComment.java
1
请完成以下Java代码
private void forwardSomeResponseHttpHeaders(@NonNull final HttpServletResponse servletResponse, @Nullable final HttpHeaders httpHeaders) { if (httpHeaders == null || httpHeaders.isEmpty()) { return; } httpHeaders.keySet() .stream() .filter(key -> !key.equals(HttpHeaders.CONNECTION)) .filter(key...
{ httpHeaders.add(API_RESPONSE_HEADER_REQUEST_AUDIT_ID, String.valueOf(apiRequestAudit.getIdNotNull().getRepoId())); } return apiResponse.toBuilder().httpHeaders(httpHeaders).build(); } } @SuppressWarnings("BooleanMethodIsAlwaysInverted") private boolean isResetServletResponse(@NonNull final HttpServle...
repos\metasfresh-new_dawn_uat\backend\de.metas.util.web\src\main\java\de\metas\util\web\audit\ResponseHandler.java
1
请在Spring Boot框架中完成以下Java代码
public void save(@NonNull final ServiceRepairProjectTask task) { final I_C_Project_Repair_Task record = getRecordById(task.getId()); updateRecord(record, task); saveRecord(record); } public ImmutableSet<ServiceRepairProjectTaskId> retainIdsOfType( @NonNull final ImmutableSet<ServiceRepairProjectTaskId> tas...
} public Optional<ServiceRepairProjectTask> getTaskByRepairOrderId( @NonNull final ProjectId projectId, @NonNull final PPOrderId repairOrderId) { return getTaskIdByRepairOrderId(projectId, repairOrderId).map(this::getById); } public Optional<ServiceRepairProjectTaskId> getTaskIdByRepairOrderId( @NonNul...
repos\metasfresh-new_dawn_uat\backend\de.metas.servicerepair.base\src\main\java\de\metas\servicerepair\project\repository\ServiceRepairProjectTaskRepository.java
2
请完成以下Java代码
protected boolean afterSave(boolean newRecord, boolean success) { if (isActive()) { setDataToLevel(); listChildRecords(); } return true; } private String setDataToLevel() { String info = "-"; if (isClientLevelOnly()) { StringBuilder sql = new StringBuilder("UPDATE ") .append(getTableNam...
+ " AND c.ColumnName IN (SELECT ColumnName FROM AD_Column cc " + "WHERE cc.IsKey='Y' AND cc.AD_Table_ID=?))"; PreparedStatement pstmt = null; ResultSet rs = null; try { pstmt = DB.prepareStatement(sql, null); pstmt.setInt(1, getAD_Table_ID()); rs = pstmt.executeQuery(); while (rs.next()) { ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-legacy\org\compiere\model\MClientShare.java
1
请完成以下Java代码
public ProfilePayload follow(@InputArgument("username") String username) { User user = SecurityUtil.getCurrentUser().orElseThrow(AuthenticationException::new); return userRepository .findByUsername(username) .map( target -> { FollowRelation followRelation = new FollowRe...
userRepository.removeRelation(relation); Profile profile = buildProfile(username, user); return ProfilePayload.newBuilder().profile(profile).build(); }) .orElseThrow(ResourceNotFoundException::new); } private Profile buildProfile(@InputArgument("username") String use...
repos\spring-boot-realworld-example-app-master\src\main\java\io\spring\graphql\RelationMutation.java
1
请完成以下Java代码
public void setDescription (java.lang.String Description) { set_Value (COLUMNNAME_Description, Description); } /** Get Beschreibung. @return Beschreibung */ @Override public java.lang.String getDescription () { return (java.lang.String)get_Value(COLUMNNAME_Description); } /** Set Interner Name. @par...
*/ @Override public java.lang.String getInternalName () { return (java.lang.String)get_Value(COLUMNNAME_InternalName); } /** Set Name. @param Name Alphanumeric identifier of the entity */ @Override public void setName (java.lang.String Name) { set_Value (COLUMNNAME_Name, Name); } /** Get Name. ...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\de\metas\javaclasses\model\X_AD_JavaClass_Type.java
1
请完成以下Java代码
public void setAD_Role_ID (int AD_Role_ID) { if (AD_Role_ID < 0) set_Value (COLUMNNAME_AD_Role_ID, null); else set_Value (COLUMNNAME_AD_Role_ID, Integer.valueOf(AD_Role_ID)); } /** Get Role. @return Responsibility Role */ public int getAD_Role_ID () { Integer ii = (Integer)get_Value(COLUMNNAME...
/** Set Web Menu. @param U_WebMenu_ID Web Menu */ public void setU_WebMenu_ID (int U_WebMenu_ID) { if (U_WebMenu_ID < 1) set_Value (COLUMNNAME_U_WebMenu_ID, null); else set_Value (COLUMNNAME_U_WebMenu_ID, Integer.valueOf(U_WebMenu_ID)); } /** Get Web Menu. @return Web Menu */ public int getU_W...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_U_RoleMenu.java
1
请完成以下Java代码
public boolean equals(final Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final Foo other = (Foo) obj; if (name == null) { ...
} @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((name == null) ? 0 : name.hashCode()); return result; } public void setBars(List<Bar> bars) { this.bars = bars; } public void setId(final Long id) { ...
repos\tutorials-master\persistence-modules\spring-hibernate-6\src\main\java\com\baeldung\hibernate\cache\model\Foo.java
1
请完成以下Java代码
private Optional<ProductExclude> getBannedManufacturerFromSaleToCustomer(@NonNull final ProductId productId, @NonNull final BPartnerId partnerId) { final ProductRepository productRepo = SpringContextHolder.instance.getBean(ProductRepository.class); final Product product = productRepo.getById(productId); final BP...
.addOnlyActiveRecordsFilter() .addEqualsFilter(I_C_BPartner_Product.COLUMNNAME_C_BPartner_ID, bpartnerId) .addEqualsFilter(I_C_BPartner_Product.COLUMNNAME_EAN13_ProductCode, ean13ProductCode.getAsString()) .create() .listImmutable(I_C_BPartner_Product.class); } @Override public @NonNull List<I_C_BPa...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java\de\metas\bpartner_product\impl\BPartnerProductDAO.java
1
请在Spring Boot框架中完成以下Java代码
public class OLCandProductFromPIIPvalidator implements IOLCandValidator { private final static transient Logger logger = LogManager.getLogger(OLCandProductFromPIIPvalidator.class); private final IOLCandEffectiveValuesBL olCandEffectiveValuesBL = Services.get(IOLCandEffectiveValuesBL.class); @Override public int g...
return; } if (productId == null) { Loggables.withLogger(logger, Level.DEBUG).addLog("Supplement missing C_OLCand.M_Product_ID = {} from M_HU_PI_Item_Product_ID={}", huPIItemProduct.getM_Product_ID(), huPIItemProduct.getM_HU_PI_Item_Product_ID()); olCand.setM_Product_ID(huPIItemProduct.getM_Product_ID()); ...
repos\metasfresh-new_dawn_uat\backend\de.metas.handlingunits.base\src\main\java\de\metas\handlingunits\ordercandidate\spi\impl\OLCandProductFromPIIPvalidator.java
2
请完成以下Java代码
public String getCode() { return code; } public static final Join forCodeOrAND(final String code) { final Join join = codeToJoin.get(code); return join != null ? join : AND; } } //@formatter:off void setJoin(Join join); Join getJoin(); //@formatter:on //@formatter:off IUserQueryField getSea...
Object getValueTo(); void setValueTo(Object valueTo); //@formatter:on /** @return true if restriction is empty (i.e. has nothing set) */ boolean isEmpty(); boolean isMandatory(); void setMandatory(boolean mandatory); boolean isInternalParameter(); void setInternalParameter(boolean internalParameter); }
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\org\compiere\apps\search\IUserQueryRestriction.java
1
请完成以下Java代码
public void setName (java.lang.String Name) { set_Value (COLUMNNAME_Name, Name); } /** Get Name. @return Alphanumeric identifier of the entity */ @Override public java.lang.String getName () { return (java.lang.String)get_Value(COLUMNNAME_Name); } @Override public org.compiere.model.I_C_Activity ge...
@Override public int getParent_Activity_ID () { Integer ii = (Integer)get_Value(COLUMNNAME_Parent_Activity_ID); if (ii == null) return 0; return ii.intValue(); } /** Set Suchschlüssel. @param Value Search key for the record in the format required - must be unique */ @Override public void setVa...
repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_C_Activity.java
1
请完成以下Java代码
public static boolean setAttribute(String word, Nature... natures) { if (natures == null) return false; CoreDictionary.Attribute attribute = new CoreDictionary.Attribute(natures, new int[natures.length]); Arrays.fill(attribute.frequency, 1); return setAttribute(word, attribute); ...
*/ public static boolean setAttribute(String word, String natureWithFrequency) { CoreDictionary.Attribute attribute = CoreDictionary.Attribute.create(natureWithFrequency); return setAttribute(word, attribute); } /** * 将字符串词性转为Enum词性 * @param name 词性名称 * @param customNatur...
repos\springboot-demo-master\hanlp\src\main\java\demo\hankcs\hanlp\utility\LexiconUtility.java
1
请完成以下Java代码
private static void updateHeaderNow(final Set<OrderId> orderIds) { // shall not happen if (orderIds.isEmpty()) { return; } // Update Order Header: TotalLines { final ArrayList<Object> sqlParams = new ArrayList<>(); final String sql = "UPDATE C_Order o" + " SET TotalLines=" + "(SELECT CO...
new AdempiereException("Updating TotalLines failed for C_Order_IDs=" + orderIds); } } // Update Order Header: GrandTotal { final ArrayList<Object> sqlParams = new ArrayList<>(); final String sql = "UPDATE C_Order o " + " SET GrandTotal=TotalLines+" // SUM up C_OrderTax.TaxAmt only for those lin...
repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java-legacy\org\compiere\model\MOrderLine.java
1
请完成以下Java代码
private final void assertConfigurable() { // nothing } public LUTUAssignBuilder setContext(final IContextAware context) { assertConfigurable(); _context = context; return this; } private IContextAware getContext() { return _context; } public LUTUAssignBuilder setLU_PI(final I_M_HU_PI luPI) { as...
public LUTUAssignBuilder setC_BPartner(final I_C_BPartner bpartner) { assertConfigurable(); this._bpartnerId = bpartner != null ? BPartnerId.ofRepoId(bpartner.getC_BPartner_ID()) : null; return this; } private final BPartnerId getBPartnerId() { return _bpartnerId; } public LUTUAssignBuilder setC_BPartne...
repos\metasfresh-new_dawn_uat\backend\de.metas.handlingunits.base\src\main\java\de\metas\handlingunits\allocation\transfer\impl\LUTUAssignBuilder.java
1
请在Spring Boot框架中完成以下Java代码
public class EDIMProductLookupUPCVType { @XmlElement(name = "UPC", required = true) protected String upc; @XmlElement(name = "GLN", required = true) protected String gln; /** * Gets the value of the upc property. * * @return * possible object is * {@link String } ...
* Gets the value of the gln property. * * @return * possible object is * {@link String } * */ public String getGLN() { return gln; } /** * Sets the value of the gln property. * * @param value * allowed object is * {@link ...
repos\metasfresh-new_dawn_uat\misc\services\camel\de-metas-camel-edi\src\main\java-xjc_metasfreshinhousev1\de\metas\edi\esb\jaxb\metasfreshinhousev1\EDIMProductLookupUPCVType.java
2
请在Spring Boot框架中完成以下Java代码
public class InventoryLineHUId implements RepoIdAware { int repoId; private InventoryLineHUId(int repoId) { this.repoId = assumeGreaterThanZero(repoId, "M_InventoryLine_HU_ID"); } public static InventoryLineHUId ofRepoId(int repoId) { return new InventoryLineHUId(repoId); } @Nullable public static Inven...
@NonNull public static InventoryLineHUId ofObject(@NonNull final Object obj) { return RepoIdAwares.ofObject(obj, InventoryLineHUId.class, InventoryLineHUId::ofRepoId); } @Override @JsonValue public int getRepoId() { return repoId; } public static boolean equals(final InventoryLineHUId id1, final Invento...
repos\metasfresh-new_dawn_uat\backend\de.metas.handlingunits.base\src\main\java\de\metas\handlingunits\inventory\InventoryLineHUId.java
2