instruction string | input string | output string | source_file string | priority int64 |
|---|---|---|---|---|
请完成以下Java代码 | public class MNewsItem extends X_CM_NewsItem
{
/**
*
*/
private static final long serialVersionUID = -8217571535161436997L;
/***
* Standard Constructor
*
* @param ctx context
* @param CM_NewsItem_ID id
* @param trxName transaction
*/
public MNewsItem (Properties ctx, int CM_News... | * Insert
* - create / update index
* @param newRecord insert
* @param success save success
* @return true if saved
*/
protected boolean afterSave (boolean newRecord, boolean success)
{
if (!success)
return success;
if (!newRecord)
{
MIndex.cleanUp(get_TrxName(), getAD_Client_ID(), get_Table_ID... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-legacy\org\compiere\model\MNewsItem.java | 1 |
请完成以下Java代码 | public static Function<ServerRequest, ServerRequest> uri(String uri) {
return uri(URI.create(uri));
}
public static Function<ServerRequest, ServerRequest> uri(URI uri) {
return request -> {
MvcUtils.setRequestUrl(request, uri);
return request;
};
}
public static class FallbackHeadersConfig {
privat... | public void setExecutionExceptionMessageHeaderName(String executionExceptionMessageHeaderName) {
this.executionExceptionMessageHeaderName = executionExceptionMessageHeaderName;
}
public String getRootCauseExceptionTypeHeaderName() {
return rootCauseExceptionTypeHeaderName;
}
public void setRootCauseExce... | repos\spring-cloud-gateway-main\spring-cloud-gateway-server-webmvc\src\main\java\org\springframework\cloud\gateway\server\mvc\filter\BeforeFilterFunctions.java | 1 |
请完成以下Java代码 | private void writeLine(final CharSequence line)
{
try
{
writer.append(line.toString());
writer.append(lineEnding);
}
catch (final IOException ex)
{
throw new AdempiereException("Failed writing CSV line: " + line, ex);
}
linesWrote++;
}
private String toCsvValue(@Nullable final Object valueOb... | writer.flush();
}
catch (IOException ex)
{
throw new AdempiereException("Failed flushing CSV data to file", ex);
}
finally
{
if (writer != null)
{
try
{
writer.close();
}
catch (IOException e)
{
// shall not happen
e.printStackTrace(); // NOPMD by tsa on 3/13/13 1... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\impexp\spreadsheet\csv\CSVWriter.java | 1 |
请完成以下Java代码 | public String getInvolvedUser() {
return involvedUser;
}
public IdentityLinkQueryObject getInvolvedUserIdentityLink() {
return involvedUserIdentityLink;
}
public Set<String> getInvolvedGroups() {
return involvedGroups;
}
public IdentityLinkQueryObject getInvolvedGr... | public List<List<String>> getSafeCaseInstanceIds() {
return safeCaseInstanceIds;
}
public void setSafeCaseInstanceIds(List<List<String>> safeCaseInstanceIds) {
this.safeCaseInstanceIds = safeCaseInstanceIds;
}
public List<List<String>> getSafeInvolvedGroups() {
return safeInvol... | repos\flowable-engine-main\modules\flowable-cmmn-engine\src\main\java\org\flowable\cmmn\engine\impl\history\HistoricCaseInstanceQueryImpl.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public class LotteryService {
private final String contractAddress;
private final Web3j web3j;
private final LotteryProperties config;
public LotteryService(String contractAddress, Web3j web3j, LotteryProperties config) {
this.contractAddress = contractAddress;
this.web3j = web3j;
... | }
public void pickWinner(String ownerAddress) throws Exception {
Lottery lottery = loadContract(ownerAddress);
lottery.pickWinner().send();
}
private Lottery loadContract(String accountAddress) {
return Lottery.load(contractAddress, web3j, txManager(accountAddress), config.gas());
... | repos\springboot-demo-master\Blockchain\src\main\java\com\et\bc\service\LotteryService.java | 2 |
请完成以下Java代码 | public String getOuterOrderBy() {
String outerOrderBy = getOrderBy();
if (outerOrderBy == null || outerOrderBy.isEmpty()) {
return "ID_ asc";
}
else if (outerOrderBy.contains(".")) {
return outerOrderBy.substring(outerOrderBy.lastIndexOf(".") + 1);
}
else {
return outerOrderBy;... | }
for (VariableQueryParameterDto variable : variables) {
QueryVariableValue value = new QueryVariableValue(
variable.getName(),
resolveVariableValue(variable.getValue()),
ConditionQueryParameterDto.getQueryOperator(variable.getOperator()),
false);
value.initiali... | repos\camunda-bpm-platform-master\webapps\assembly\src\main\java\org\camunda\bpm\cockpit\impl\plugin\base\dto\query\AbstractProcessInstanceQueryDto.java | 1 |
请完成以下Java代码 | public String getProcessDefinitionKey() {
return processDefinitionKey;
}
public void setProcessDefinitionKey(String processDefinitionKey) {
this.processDefinitionKey = processDefinitionKey;
}
public String getProcessDefinitionId() {
return processDefinitionId;
}
public void setProcessDefiniti... | this.tenantId = tenantId;
}
@Override
public String toString() {
return this.getClass().getSimpleName()
+ "[" +
"count=" + count +
", processDefinitionKey='" + processDefinitionKey + '\'' +
", processDefinitionId='" + processDefinitionId + '\'' +
", processDefinitionName='" + proc... | repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\persistence\entity\TaskReportResultEntity.java | 1 |
请完成以下Java代码 | public class ProcessApplicationReferenceImpl implements ProcessApplicationReference {
private static ProcessApplicationLogger LOG = ProcessEngineLogger.PROCESS_APPLICATION_LOGGER;
/** the weak reference to the process application */
protected WeakReference<AbstractProcessApplication> processApplication;
prot... | throw LOG.processApplicationUnavailableException(name);
}
else {
return application;
}
}
public void processEngineStopping(ProcessEngine processEngine) throws ProcessApplicationUnavailableException {
// do nothing
}
public void clear() {
processApplication.clear();
}
} | repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\application\impl\ProcessApplicationReferenceImpl.java | 1 |
请完成以下Java代码 | public V remove(K key) throws CacheException {
BoundHashOperations<String, K, V> hash = redisTemplate.boundHashOps(cacheKey);
V value = null;
try {
Object k = hashKey(key);
value = hash.get(k);
hash.delete(k);
} catch (Exce... | @Override
public Collection<V> values() {
BoundHashOperations<String, K, V> hash = redisTemplate.boundHashOps(cacheKey);
return hash.values();
}
protected Object hashKey(K key) {
//此处很重要,如果key是登录凭证,那么这是访问用户的授权缓存;将登录凭证转为user对象,返回user的id属性做为hash key,否则会以user对象做... | repos\springBoot-master\springboot-shiro2\src\main\java\cn\abel\rest\shiro\ShiroRedisCacheManager.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public class DocOutboundConfigRepository
{
@NonNull private final IQueryBL queryBL = Services.get(IQueryBL.class);
@NonNull private final CCache<Integer, DocOutboundConfigMap> cache = CCache.<Integer, DocOutboundConfigMap>builder()
.tableName(I_C_Doc_Outbound_Config.Table_Name)
.maximumSize(1)
.build();
p... | .map(DocOutboundConfigRepository::ofRecord)
.collect(ImmutableList.toImmutableList());
return new DocOutboundConfigMap(docOutboundConfig);
}
private static DocOutboundConfig ofRecord(@NotNull final I_C_Doc_Outbound_Config record)
{
return DocOutboundConfig.builder()
.id(DocOutboundConfigId.ofRepoId(rec... | repos\metasfresh-new_dawn_uat\backend\de.metas.document.archive\de.metas.document.archive.base\src\main\java\de\metas\document\archive\config\DocOutboundConfigRepository.java | 2 |
请完成以下Java代码 | public void setA_Proceeds (BigDecimal A_Proceeds)
{
set_Value (COLUMNNAME_A_Proceeds, A_Proceeds);
}
/** Get A_Proceeds.
@return A_Proceeds */
public BigDecimal getA_Proceeds ()
{
BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_A_Proceeds);
if (bd == null)
return Env.ZERO;
return bd;
}
public... | }
/** Get Processed.
@return The document has been processed
*/
public boolean isProcessed ()
{
Object oo = get_Value(COLUMNNAME_Processed);
if (oo != null)
{
if (oo instanceof Boolean)
return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Process No... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_A_Asset_Disposed.java | 1 |
请完成以下Java代码 | protected void validateParams(String userId, String groupId, String type, String taskId) {
if (taskId == null) {
throw new FlowableIllegalArgumentException("taskId is null");
}
if (type == null) {
throw new FlowableIllegalArgumentException("type is required when adding a... | @Override
protected Void execute(CommandContext commandContext, TaskEntity task) {
CmmnEngineConfiguration cmmnEngineConfiguration = CommandContextUtil.getCmmnEngineConfiguration(commandContext);
if (IdentityLinkType.ASSIGNEE.equals(type)) {
TaskHelper.changeTaskAssignee(task, null, cmmn... | repos\flowable-engine-main\modules\flowable-cmmn-engine\src\main\java\org\flowable\cmmn\engine\impl\cmd\DeleteIdentityLinkCmd.java | 1 |
请完成以下Java代码 | public class MDistributionRun extends X_M_DistributionRun
{
/**
*
*/
private static final long serialVersionUID = -4355723603388382287L;
/**
* Standard Constructor
* @param ctx context
* @param M_DistributionRun_ID id
* @param trxName transaction
*/
public MDistributionRun (Properties ctx, int M_D... | if (!reload && m_lines != null) {
set_TrxName(m_lines, get_TrxName());
return m_lines;
}
//
String sql = "SELECT * FROM M_DistributionRunLine "
+ "WHERE M_DistributionRun_ID=? AND IsActive='Y' AND TotalQty IS NOT NULL AND TotalQty<> 0 ORDER BY Line";
ArrayList<MDistributionRunLine> list = new ArrayList... | repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java-legacy\org\compiere\model\MDistributionRun.java | 1 |
请完成以下Java代码 | public void setMessage(String[] messageParts) {
StringBuilder stringBuilder = new StringBuilder();
for (String part : messageParts) {
if (part != null) {
stringBuilder.append(part.replace(MESSAGE_PARTS_MARKER, " | "));
stringBuilder.append(MESSAGE_PARTS_MARKER... | this.taskId = taskId;
}
public String getMessage() {
return message;
}
public void setMessage(String message) {
this.message = message;
}
public Date getTime() {
return time;
}
public void setTime(Date time) {
this.time = time;
}
public String... | repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\persistence\entity\CommentEntityImpl.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public class PersonProperties implements Serializable {
private String name;
private int age;
private String sex = "M";
public PersonProperties() {
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public int ge... | }
public void setAge(int age) {
this.age = age;
}
public String getSex() {
return sex;
}
public void setSex(String sex) {
this.sex = sex;
}
} | repos\springboot-demo-master\xxx-spring-boot-starter\src\main\java\com\et\starter\PersonProperties.java | 2 |
请完成以下Java代码 | public class Bpmn20NamespaceContext implements NamespaceContext {
public static final String BPMN = "bpmn";
public static final String BPMNDI = "bpmndi";
public static final String OMGDC = "omgdc";
public static final String OMGDI = "omgdi";
/**
* This is a protected filed so you can extend t... | }
private static <T, E> Set<T> getKeysByValue(Map<T, E> map, E value) {
Set<T> keys = new HashSet<T>();
for (Entry<T, E> entry : map.entrySet()) {
if (value.equals(entry.getValue())) {
keys.add(entry.getKey());
}
}
return keys;
}
priv... | repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\bpmn\diagram\Bpmn20NamespaceContext.java | 1 |
请完成以下Java代码 | public BigDecimal getLowOrderAmount() {
return lowOrderAmount;
}
public void setLowOrderAmount(BigDecimal lowOrderAmount) {
this.lowOrderAmount = lowOrderAmount;
}
public Integer getMaxPointPerOrder() {
return maxPointPerOrder;
}
public void setMaxPointPerOrder(Integer... | }
@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(", continueSignDay=").append(continueSignDay);... | repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\UmsMemberRuleSetting.java | 1 |
请完成以下Java代码 | public class SetBenchMark {
@State(Scope.Thread)
public static class MyState {
//Set<Employee> employeeSet = new HashSet<>();
LinkedHashSet<Employee> employeeSet = new LinkedHashSet<>();
//ConcurrentSkipListSet<Employee> employeeSet = new ConcurrentSkipListSet <>();
// TreeSet... | @Benchmark
public boolean testRemove(MyState state) {
return state.employeeSet.remove(state.employee);
}
public static void main(String[] args) throws Exception {
Options options = new OptionsBuilder()
.include(SetBenchMark.class.getSimpleName()).threads(1)
... | repos\tutorials-master\core-java-modules\core-java-collections-7\src\main\java\com\baeldung\performance\SetBenchMark.java | 1 |
请完成以下Java代码 | public class CompensateEventDefinitionImpl extends EventDefinitionImpl implements CompensateEventDefinition {
protected static Attribute<Boolean> waitForCompletionAttribute;
protected static AttributeReference<Activity> activityRefAttribute;
public static void registerType(ModelBuilder modelBuilder) {
Model... | public CompensateEventDefinitionImpl(ModelTypeInstanceContext context) {
super(context);
}
public boolean isWaitForCompletion() {
return waitForCompletionAttribute.getValue(this);
}
public void setWaitForCompletion(boolean isWaitForCompletion) {
waitForCompletionAttribute.setValue(this, isWaitForC... | repos\camunda-bpm-platform-master\model-api\bpmn-model\src\main\java\org\camunda\bpm\model\bpmn\impl\instance\CompensateEventDefinitionImpl.java | 1 |
请在Spring Boot框架中完成以下Java代码 | private WFProcess processWFActivity(
@NonNull final UserId invokerId,
@NonNull final WFProcessId wfProcessId,
@NonNull final WFActivityId wfActivityId,
@NonNull final BiFunction<WFProcess, WFActivity, WFProcess> processor)
{
return changeWFProcessById(
wfProcessId,
wfProcess -> {
wfProcess.a... | {
WFProcess wfProcessChanged = wfProcess;
for (final WFActivity wfActivity : wfProcess.getActivities())
{
final WFActivityStatus newActivityStatus = wfActivityHandlersRegistry
.getHandler(wfActivity.getWfActivityType())
.computeActivityState(wfProcessChanged, wfActivity);
wfProcessChanged = wfPr... | repos\metasfresh-new_dawn_uat\backend\de.metas.workflow.rest-api\src\main\java\de\metas\workflow\rest_api\service\WorkflowRestAPIService.java | 2 |
请完成以下Java代码 | public void init(IInfoSimple parent, I_AD_InfoColumn infoColumn, String searchText)
{
this.parent = parent;
this.infoColumn = infoColumn;
}
@Override
public I_AD_InfoColumn getAD_InfoColumn()
{
return infoColumn;
}
@Override
public String getLabel(int index)
{
return Msg.translate(Env.getCtx(), "Spon... | final String searchText = getText();
if (sno == null && !Check.isEmpty(searchText, true))
return new String[]{"1=2"};
if (sno == null)
return null;
final Timestamp date = TimeUtil.trunc(Env.getContextAsDate(Env.getCtx(), "#Date"), TimeUtil.TRUNC_DAY);
//
final String whereClause = "EXISTS (SELECT 1 FR... | repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\org\compiere\apps\search\InfoQueryCriteriaBPSonsorAbstract.java | 1 |
请完成以下Java代码 | public void addActionListener(final ActionListener listener)
{
} // addActionListener
@Override
public void actionPerformed(final ActionEvent e)
{
try
{
if (e.getSource() == m_button)
{
actionButton();
}
}
catch (final Exception ex)
{
Services.get(IClientUI.class).error(attributeContex... | {
requestFocus();
}
}
@Override
public boolean isAutoCommit()
{
return true;
}
@Override
public void addMouseListener(final MouseListener l)
{
m_text.addMouseListener(l);
}
} // VPAttribute | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java-legacy\org\compiere\grid\ed\VPAttribute.java | 1 |
请完成以下Java代码 | public String toString()
{
return MoreObjects.toStringHelper("memoizing")
.addValue(delegate)
.add("keyFunction", keyFunction)
.toString();
}
@Override
public R apply(final T input)
{
return values.computeIfAbsent(keyFunction.apply(input), k -> delegate.apply(input));
}
@Override
... | finally
{
// Downgrade to read lock
lock.readLock().lock(); // acquire read lock before releasing write lock
readLockAcquired = true;
lock.writeLock().unlock(); // unlock write, still hold read
writeLockAcquired = false;
}
}
finally
{
if (writeLockAcquired)
{
lock.... | repos\metasfresh-new_dawn_uat\backend\de.metas.util\src\main\java\de\metas\util\Functions.java | 1 |
请完成以下Java代码 | public String prepareTable(ColumnInfo[] layout, String from, String where, boolean multiSelection, String tableName)
{
for (int i = 0; i < layout.length; i++)
{
if (layout[i].getColClass() == IDColumn.class)
{
idColumnIndex = i;
break;
}
}
sql = super.prepareTable(layout, from, where, multiSel... | public void selectById(int id)
{
selectById(id, true);
}
public void selectById(int id, boolean fireEvent)
{
if (idColumnIndex < 0)
return;
boolean fireSelectionEventOld = fireSelectionEvent;
try
{
fireSelectionEvent = fireEvent;
if (id < 0)
{
this.getSelectionModel().removeSelectionInte... | repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\adempiere\ui\swing\MiniTable2.java | 1 |
请完成以下Java代码 | public String DropShipPartner(final ICalloutField calloutField)
{
if (calloutField.isRecordCopyingMode())
{
// 05291: In case current record is on dataNew phase with Copy option set
// then just don't update the DropShip fields, take them as they were copied
return NO_ERROR;
}
final I_C_Order order =... | .build());
}
order.setDropShip_User_ID(-1);
}
}
return NO_ERROR;
}
private static boolean isEnforcePriceLimit(final I_C_OrderLine orderLine, final boolean isSOTrx)
{
// We enforce PriceLimit only for sales orders
if (!isSOTrx)
{
return false;
}
return orderLine.isEnforcePriceLimit();
... | repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java-legacy\org\compiere\model\CalloutOrder.java | 1 |
请完成以下Java代码 | public static ContextPath root(@NonNull final DocumentEntityDescriptor entityDescriptor)
{
return new ContextPath(ImmutableList.of(ContextPathElement.ofNameAndId(
extractName(entityDescriptor),
entityDescriptor.getWindowId().toInt())
));
}
static String extractName(final @NonNull DocumentEntityDescript... | class ContextPathElement
{
@NonNull String name;
int id;
@JsonCreator
public static ContextPathElement ofJson(@NonNull final String json)
{
try
{
final int idx = json.indexOf("/");
if (idx > 0)
{
String name = json.substring(0, idx);
int id = Integer.parseInt(json.substring(idx + 1));
ret... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\window\health\ContextPath.java | 1 |
请完成以下Java代码 | public Object call() throws Exception
{
try
{
final Object result = proceed();
return result == null ? NullResult : result;
}
catch (Exception e)
{
throw e;
}
catch (Throwable e)
{
Throwables.propagateIfPossible(e);
throw Throwables.propagate(e);
}
}
@Override | public Object getTarget()
{
return target;
}
@Override
public Object[] getParameters()
{
return methodArgs;
}
@Override
public Method getMethod()
{
return method;
}
} | repos\metasfresh-new_dawn_uat\backend\de.metas.util\src\main\java\org\adempiere\util\proxy\impl\InvocationContext.java | 1 |
请完成以下Java代码 | public boolean equals(Object obj) {
if (obj instanceof Bindings) {
Bindings other = (Bindings) obj;
return (
Arrays.equals(functions, other.functions) &&
Arrays.equals(variables, other.variables) &&
converter.equals(other.converter)
... | for (int i = 0; i < wrappers.length; i++) {
wrappers[i] = new MethodWrapper(functions[i]);
}
out.writeObject(wrappers);
}
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
in.defaultReadObject();
MethodWrapper[] wrappers = (Me... | repos\Activiti-develop\activiti-core-common\activiti-juel-jakarta\src\main\java\org\activiti\core\el\juel\tree\Bindings.java | 1 |
请完成以下Java代码 | private void load0(String trxName) throws ParserConfigurationException, SAXException, IOException
{
this.objects = new ArrayList<Object>();
final IXMLHandlerFactory factory = Services.get(IXMLHandlerFactory.class);
final DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
dbf.setNamespaceAware... | }
private InputSource getInputSource()
{
if (fileName != null)
{
return new InputSource(fileName);
}
else if (inputStream != null)
{
return new InputSource(inputStream);
}
else
{
throw new AdempiereException("Cannot identify source");
}
}
private void addLog(String msg)
{
logger.info... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\org\adempiere\ad\migration\xml\XMLLoader.java | 1 |
请完成以下Java代码 | public PlanItemTransition getStandardEvent() {
PlanItemTransitionStandardEvent child = standardEventChild.getChild(this);
return child.getValue();
}
public void setStandardEvent(PlanItemTransition standardEvent) {
PlanItemTransitionStandardEvent child = standardEventChild.getChild(this);
child.setV... | return new PlanItemStartTriggerImpl(instanceContext);
}
});
sourceRefAttribute = typeBuilder.stringAttribute(CMMN_ATTRIBUTE_SOURCE_REF)
.idAttributeReference(PlanItem.class)
.build();
SequenceBuilder sequenceBuilder = typeBuilder.sequence();
standardEventChild = sequence... | repos\camunda-bpm-platform-master\model-api\cmmn-model\src\main\java\org\camunda\bpm\model\cmmn\impl\instance\PlanItemStartTriggerImpl.java | 1 |
请完成以下Java代码 | public class FunctionalJavaIOMain {
public static IO<Unit> printLetters(final String s) {
return () -> {
for (int i = 0; i < s.length(); i++) {
System.out.println(s.charAt(i));
}
return Unit.unit();
};
}
public static void main(String[] a... | IO<String> readInput = IOFunctions.stdinReadLine();
F<String, String> toUpperCase = i -> i.toUpperCase();
F<String, IO<Unit>> transformInput = F1Functions.<String, IO<Unit>, String> o(printLetters).f(toUpperCase);
IO<Unit> readAndPrintResult = IOFunctions.bind(readInput, transformInput);
... | repos\tutorials-master\libraries-6\src\main\java\com\baeldung\fj\FunctionalJavaIOMain.java | 1 |
请完成以下Java代码 | public HistoricProcessInstanceQueryDto getHistoricProcessInstanceQuery() {
return historicProcessInstanceQuery;
}
public void setHistoricProcessInstanceQuery(HistoricProcessInstanceQueryDto historicProcessInstanceQuery) {
this.historicProcessInstanceQuery = historicProcessInstanceQuery;
}
public boole... | return updateInChunks;
}
public void setUpdateInChunks(boolean updateInChunks) {
this.updateInChunks = updateInChunks;
}
public Integer getUpdateChunkSize() {
return updateChunkSize;
}
public void setUpdateChunkSize(Integer updateChunkSize) {
this.updateChunkSize = updateChunkSize;
}
} | repos\camunda-bpm-platform-master\engine-rest\engine-rest\src\main\java\org\camunda\bpm\engine\rest\dto\history\batch\removaltime\SetRemovalTimeToHistoricProcessInstancesDto.java | 1 |
请完成以下Java代码 | public static DelegateExecution getMultiInstanceRootExecution(ExecutionEntity execution) {
ExecutionEntity multiInstanceRootExecution = null;
ExecutionEntity currentExecution = execution;
while (currentExecution != null && multiInstanceRootExecution == null && currentExecution.getParentId() != n... | List<String> boundaryEventActivityIds = new ArrayList<>();
List<BoundaryEvent> boundaryEvents = process.findFlowElementsOfType(BoundaryEvent.class, true);
for (BoundaryEvent boundaryEvent : boundaryEvents) {
if (activityId.equals(boundaryEvent.getAttachedToRefId())) {
... | repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\util\ExecutionGraphUtil.java | 1 |
请完成以下Java代码 | private Action createPackAllAction()
{
//TODO: localization
BoundAction action = new BoundAction("Size All Column", PACK_ALL_COMMAND);
action.setLongDescription("Size all column to fit content");
action.registerCallback(this, "packAll");
return action;
}
/**
* Size all column to fit content.
*
* ... | sorting = true;
try
{
// other sort columns
final boolean sortAscending = addToSortColumnsAndRemoveOtherColumns(modelColumnIndex);
gridTable.sort(modelColumnIndex, sortAscending);
}
finally
{
sorting = false;
}
// table model fires "Sorted" DataStatus event which causes... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java-legacy\org\compiere\grid\VTable.java | 1 |
请完成以下Java代码 | public int getGL_BudgetControl_ID ()
{
Integer ii = (Integer)get_Value(COLUMNNAME_GL_BudgetControl_ID);
if (ii == null)
return 0;
return ii.intValue();
}
public I_GL_Budget getGL_Budget() throws RuntimeException
{
return (I_GL_Budget)MTable.get(getCtx(), I_GL_Budget.Table_Name)
.getPO(getGL_Budg... | @param IsBeforeApproval
The Check is before the (manual) approval
*/
public void setIsBeforeApproval (boolean IsBeforeApproval)
{
set_Value (COLUMNNAME_IsBeforeApproval, Boolean.valueOf(IsBeforeApproval));
}
/** Get Before Approval.
@return The Check is before the (manual) approval
*/
public boolean ... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_GL_BudgetControl.java | 1 |
请完成以下Java代码 | public abstract class EntitiesExportCtx<R extends VersionCreateRequest> {
protected final User user;
protected final CommitGitRequest commit;
protected final R request;
private final List<ListenableFuture<Void>> futures;
private final Map<EntityId, EntityId> externalIdMap;
public EntitiesExpor... | }
public abstract EntityExportSettings getSettings();
@SuppressWarnings("unchecked")
public <ID extends EntityId> ID getExternalId(ID internalId) {
var result = externalIdMap.get(internalId);
log.debug("[{}][{}] Local cache {} for id", internalId.getEntityType(), internalId.getId(), result... | repos\thingsboard-master\application\src\main\java\org\thingsboard\server\service\sync\vc\data\EntitiesExportCtx.java | 1 |
请完成以下Java代码 | private static Chain initChain(ExecutionGraphQlService service, List<RSocketGraphQlInterceptor> interceptors) {
Chain endOfChain = (request) -> service.execute(request).map(RSocketGraphQlResponse::new);
return interceptors.isEmpty() ? endOfChain :
interceptors.stream()
.reduce(RSocketGraphQlInterceptor::a... | return Flux.error(new RejectedException(errorData));
});
}
private Mono<RSocketGraphQlResponse> handleInternal(Map<String, Object> payload) {
String requestId = this.idGenerator.generateId().toString();
return this.executionChain.next(new RSocketGraphQlRequest(payload, requestId, null));
}
@SuppressWarnin... | repos\spring-graphql-main\spring-graphql\src\main\java\org\springframework\graphql\server\GraphQlRSocketHandler.java | 1 |
请完成以下Java代码 | public abstract class BasePageDataIterable<T> implements Iterable<T>, Iterator<T> {
private final int fetchSize;
private List<T> currentItems;
private int currentIdx;
private boolean hasNextPack;
private PageLink nextPackLink;
private boolean initialized;
public BasePageDataIterable(int f... | if (hasNextPack) {
fetch(nextPackLink);
}
}
return currentIdx < currentItems.size();
}
@Override
public T next() {
if (!hasNext()) {
throw new NoSuchElementException();
}
return currentItems.get(currentIdx++);
}
privat... | repos\thingsboard-master\common\data\src\main\java\org\thingsboard\server\common\data\page\BasePageDataIterable.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public class IncidentRestService extends AbstractPluginResource {
public final static String PATH = "/incident";
public IncidentRestService(String engineName) {
super(engineName);
}
@GET
@Produces(MediaType.APPLICATION_JSON)
public List<IncidentDto> getIncidents(@Context UriInfo uriInfo,
@Query... | return queryIncidentsCount(queryParameter);
}
@POST
@Path("/count")
@Consumes(MediaType.APPLICATION_JSON)
@Produces(MediaType.APPLICATION_JSON)
public CountResultDto queryIncidentsCount(IncidentQueryDto queryParameter) {
CountResultDto result = new CountResultDto();
configureExecutionQuery(queryPar... | repos\camunda-bpm-platform-master\webapps\assembly\src\main\java\org\camunda\bpm\cockpit\impl\plugin\resources\IncidentRestService.java | 2 |
请完成以下Java代码 | public abstract class AclFormattingUtils {
public static String demergePatterns(String original, String removeBits) {
Assert.notNull(original, "Original string required");
Assert.notNull(removeBits, "Bits To Remove string required");
Assert.isTrue(original.length() == removeBits.length(),
"Original and Bits... | /**
* Returns a representation of the active bits in the presented mask, with each active
* bit being denoted by the passed character.
* <p>
* Inactive bits will be denoted by character {@link Permission#RESERVED_OFF}.
* @param mask the integer bit mask to print the active bits for
* @param code the charact... | repos\spring-security-main\acl\src\main\java\org\springframework\security\acls\domain\AclFormattingUtils.java | 1 |
请完成以下Java代码 | public ActivityInstanceDto[] getChildActivityInstances() {
return childActivityInstances;
}
public TransitionInstanceDto[] getChildTransitionInstances() {
return childTransitionInstances;
}
/** the list of executions that are currently waiting in this activity instance */
public String[] getExecutio... | return incidents;
}
public static ActivityInstanceDto fromActivityInstance(ActivityInstance instance) {
ActivityInstanceDto result = new ActivityInstanceDto();
result.id = instance.getId();
result.parentActivityInstanceId = instance.getParentActivityInstanceId();
result.activityId = instance.getAct... | repos\camunda-bpm-platform-master\engine-rest\engine-rest\src\main\java\org\camunda\bpm\engine\rest\dto\runtime\ActivityInstanceDto.java | 1 |
请完成以下Java代码 | public List<String> shortcutFieldOrder() {
return Collections.singletonList("host");
}
@Override
public GatewayFilter apply(Config config) {
return new GatewayFilter() {
@Override
public Mono<Void> filter(ServerWebExchange exchange, GatewayFilterChain chain) {
String value = ServerWebExchangeUtils.exp... | .toString();
}
};
}
public static class Config {
private @Nullable String host;
public @Nullable String getHost() {
return host;
}
public void setHost(String host) {
this.host = host;
}
}
} | repos\spring-cloud-gateway-main\spring-cloud-gateway-server-webflux\src\main\java\org\springframework\cloud\gateway\filter\factory\SetRequestHostHeaderGatewayFilterFactory.java | 1 |
请完成以下Java代码 | public String getDescription ()
{
return (String)get_Value(COLUMNNAME_Description);
}
/** Set Time based.
@param IsTimeBased
Time based Revenue Recognition rather than Service Level based
*/
public void setIsTimeBased (boolean IsTimeBased)
{
set_Value (COLUMNNAME_IsTimeBased, Boolean.valueOf(IsTimeBa... | }
/** Set Number of Months.
@param NoMonths Number of Months */
public void setNoMonths (int NoMonths)
{
set_Value (COLUMNNAME_NoMonths, Integer.valueOf(NoMonths));
}
/** Get Number of Months.
@return Number of Months */
public int getNoMonths ()
{
Integer ii = (Integer)get_Value(COLUMNNAME_NoMont... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_C_RevenueRecognition.java | 1 |
请完成以下Java代码 | private static String getLocationFieldNameForBPartnerField(final String bpartnerFieldName)
{
switch (bpartnerFieldName)
{
case I_C_Order.COLUMNNAME_C_BPartner_ID:
return I_C_Order.COLUMNNAME_C_BPartner_Location_ID;
case I_C_Order.COLUMNNAME_Bill_BPartner_ID:
return I_C_Order.COLUMNNAME_Bill_Location_... | @Nullable
private static String getUserIdFieldNameForBPartnerField(final String bpartnerFieldName)
{
switch (bpartnerFieldName)
{
case I_C_Order.COLUMNNAME_C_BPartner_ID:
return I_C_Order.COLUMNNAME_AD_User_ID;
case I_C_Order.COLUMNNAME_Bill_BPartner_ID:
return I_C_Order.COLUMNNAME_Bill_User_ID;
... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\window\descriptor\AdvancedSearchBPartnerProcessor.java | 1 |
请完成以下Java代码 | public void addEmptyHUListener(@NonNull final EmptyHUListener emptyHUListener)
{
emptyHUListeners.add(emptyHUListener);
}
@Override
public List<EmptyHUListener> getEmptyHUListeners()
{
return ImmutableList.copyOf(emptyHUListeners);
}
@Override
public void flush()
{
final IAttributeStorageFactory attrib... | }
@Override
public boolean isDontDestroyHu(@NonNull final HuId huId)
{
return huIdsToNotDestroy.contains(huId);
}
@Override
public boolean isPropertyTrue(@NonNull final String propertyName)
{
final Boolean isPropertyTrue = getProperty(propertyName);
return isPropertyTrue != null && isPropertyTrue;
}
} | repos\metasfresh-new_dawn_uat\backend\de.metas.handlingunits.base\src\main\java\de\metas\handlingunits\impl\MutableHUContext.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public List<HistoricIdentityLinkEntity> findHistoricIdentityLinksByScopeIdAndScopeType(String scopeId, String scopeType) {
return dataManager.findHistoricIdentityLinksByScopeIdAndScopeType(scopeId, scopeType);
}
@Override
public List<HistoricIdentityLinkEntity> findHistoricIdentityLinksBySubSco... | @Override
public void bulkDeleteHistoricIdentityLinksForTaskIds(Collection<String> taskIds) {
dataManager.bulkDeleteHistoricIdentityLinksForTaskIds(taskIds);
}
@Override
public void bulkDeleteHistoricIdentityLinksForScopeIdsAndScopeType(Collection<String> scopeIds, String scopeType) {
d... | repos\flowable-engine-main\modules\flowable-identitylink-service\src\main\java\org\flowable\identitylink\service\impl\persistence\entity\HistoricIdentityLinkEntityManagerImpl.java | 2 |
请完成以下Java代码 | public static void inOperator() {
Bson filter = in("userName", "Jack", "Lisa");
FindIterable<Document> documents = collection.find(filter);
printResult(documents);
}
public static void notInOperator() {
Bson filter = nin("userName", "Jack", "Lisa");
FindIterable<Documen... | public static void main(String args[]) {
setUp();
equalsOperator();
notEqualOperator();
greaterThanOperator();
lessThanOperator();
inOperator();
notInOperator();
andOperator();
orOperator();
existsOperator();
regexOperato... | repos\tutorials-master\persistence-modules\java-mongodb\src\main\java\com\baeldung\mongo\filter\FilterOperation.java | 1 |
请完成以下Java代码 | public class Author {
@Id
private final Long id;
private final String name;
private final Set<Book> books;
public Author(Long id, String name, Set<Book> books) {
this.id = id;
this.name = name;
this.books = books;
}
public Long getId() {
return id;
}
public String getName() {
return name;
}
... | if (o == null || getClass() != o.getClass()) {
return false;
}
Author author = (Author) o;
return Objects.equals(id, author.id) && Objects.equals(name, author.name)
&& Objects.equals(books, author.books);
}
@Override
public int hashCode() {
return Objects.hash(id, name, books);
}
@Override
public... | repos\spring-data-examples-main\jdbc\graalvm-native\src\main\java\example\springdata\jdbc\graalvmnative\model\Author.java | 1 |
请完成以下Java代码 | public void setDateDoc (Timestamp DateDoc)
{
set_Value (COLUMNNAME_DateDoc, DateDoc);
}
/** Get Document Date.
@return Date of the Document
*/
public Timestamp getDateDoc ()
{
return (Timestamp)get_Value(COLUMNNAME_DateDoc);
}
public I_GL_JournalBatch getGL_JournalBatch() throws RuntimeException
... | General Ledger Journal Batch
*/
public void setGL_JournalBatch_ID (int GL_JournalBatch_ID)
{
if (GL_JournalBatch_ID < 1)
set_ValueNoCheck (COLUMNNAME_GL_JournalBatch_ID, null);
else
set_ValueNoCheck (COLUMNNAME_GL_JournalBatch_ID, Integer.valueOf(GL_JournalBatch_ID));
}
/** Get Journal Batch.
@ret... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_C_Recurring_Run.java | 1 |
请完成以下Java代码 | private Mono<?> postFilter(EvaluationContext ctx, Object result, ExpressionAttribute attribute) {
return ReactiveExpressionUtils.evaluateAsBoolean(attribute.getExpression(), ctx)
.flatMap((granted) -> granted ? Mono.just(result) : Mono.empty());
}
@Override
public Pointcut getPointcut() {
return this.pointcu... | @Override
public boolean isPerInstance() {
return true;
}
@Override
public int getOrder() {
return this.order;
}
public void setOrder(int order) {
this.order = order;
}
} | repos\spring-security-main\core\src\main\java\org\springframework\security\authorization\method\PostFilterAuthorizationReactiveMethodInterceptor.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public void setCollectDate(Date collectDate) {
this.collectDate = collectDate;
}
/**
* 汇总类型(参考枚举:SettDailyCollectTypeEnum)
*
* @return
*/
public String getCollectType() {
return collectType;
}
/**
* 汇总类型(参考枚举:SettDailyCollectTypeEnum)
*
* @param collectType
*/
public void setCollectType(St... | /**
* 交易总笔数
*
* @return
*/
public Integer getTotalCount() {
return totalCount;
}
/**
* 交易总笔数
*
* @param totalCount
*/
public void setTotalCount(Integer totalCount) {
this.totalCount = totalCount;
}
/**
* 结算状态(参考枚举:SettDailyCollectStatusEnum)
*
* @return
*/
public String getSettSt... | repos\roncoo-pay-master\roncoo-pay-service\src\main\java\com\roncoo\pay\account\entity\RpSettDailyCollect.java | 2 |
请完成以下Java代码 | protected final Context context() {
return this.context;
}
/**
* Attaches the authentication context before the actual call.
*
* <p>
* This method is called after the grpc context is attached.
* </p>
*/
protected abstract void attachAuthenticationContext();
/**
... | } finally {
detachAuthenticationContext();
log.debug("onCancel - Authentication cleared");
this.context.detach(previous);
}
}
@Override
public void onComplete() {
final Context previous = this.context.attach();
try {
attachAuthenticati... | repos\grpc-spring-master\grpc-server-spring-boot-starter\src\main\java\net\devh\boot\grpc\server\security\interceptors\AbstractAuthenticatingServerCallListener.java | 1 |
请完成以下Java代码 | public Integer getPriviledgeMemberPrice() {
return priviledgeMemberPrice;
}
public void setPriviledgeMemberPrice(Integer priviledgeMemberPrice) {
this.priviledgeMemberPrice = priviledgeMemberPrice;
}
public Integer getPriviledgeBirthday() {
return priviledgeBirthday;
}
... | sb.append(", defaultStatus=").append(defaultStatus);
sb.append(", freeFreightPoint=").append(freeFreightPoint);
sb.append(", commentGrowthPoint=").append(commentGrowthPoint);
sb.append(", priviledgeFreeFreight=").append(priviledgeFreeFreight);
sb.append(", priviledgeSignIn=").append(priv... | repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\UmsMemberLevel.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public int create(UmsResource umsResource) {
umsResource.setCreateTime(new Date());
return resourceMapper.insert(umsResource);
}
@Override
public int update(Long id, UmsResource umsResource) {
umsResource.setId(id);
int count = resourceMapper.updateByPrimaryKeySelective(umsR... | }
@Override
public List<UmsResource> list(Long categoryId, String nameKeyword, String urlKeyword, Integer pageSize, Integer pageNum) {
PageHelper.startPage(pageNum,pageSize);
UmsResourceExample example = new UmsResourceExample();
UmsResourceExample.Criteria criteria = example.createCrit... | repos\mall-master\mall-admin\src\main\java\com\macro\mall\service\impl\UmsResourceServiceImpl.java | 2 |
请完成以下Java代码 | public Optional<HasId<?>> findEntity(TenantId tenantId, EntityId entityId) {
return Optional.ofNullable(findAssetProfileById(tenantId, new AssetProfileId(entityId.getId())));
}
@Override
public FluentFuture<Optional<HasId<?>>> findEntityAsync(TenantId tenantId, EntityId entityId) {
return F... | new PaginatedRemover<>() {
@Override
protected PageData<AssetProfile> findEntities(TenantId tenantId, TenantId id, PageLink pageLink) {
return assetProfileDao.findAssetProfiles(id, pageLink);
}
@Override
protected void... | repos\thingsboard-master\dao\src\main\java\org\thingsboard\server\dao\asset\AssetProfileServiceImpl.java | 1 |
请完成以下Java代码 | protected void addPartitions(QueueKey queueKey, Set<TopicPartitionInfo> partitions, RestoreCallback callback) {
Map<String, Long> eventsStartOffsets = eventsStartOffsetsProvider != null ? eventsStartOffsetsProvider.get() : null; // remembering the offsets before subscribing to states
Set<TopicPartition... | }, null);
}
@Override
protected void removePartitions(QueueKey queueKey, Set<TopicPartitionInfo> partitions) {
super.removePartitions(queueKey, partitions);
stateConsumer.removePartitions(withTopic(partitions, stateConsumer.getTopic()));
}
@Override
protected void deletePartiti... | repos\thingsboard-master\common\queue\src\main\java\org\thingsboard\server\queue\common\state\KafkaQueueStateService.java | 1 |
请完成以下Java代码 | public boolean isSelfService ()
{
Object oo = get_Value(COLUMNNAME_IsSelfService);
if (oo != null)
{
if (oo instanceof Boolean)
return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Name.
@param Name
Alphanumeric identifier of the entity
*/
@Overrid... | }
return false;
}
/** Set Verarbeiten.
@param Processing Verarbeiten */
@Override
public void setProcessing (boolean Processing)
{
set_Value (COLUMNNAME_Processing, Boolean.valueOf(Processing));
}
/** Get Verarbeiten.
@return Verarbeiten */
@Override
public boolean isProcessing ()
{
Object oo... | repos\metasfresh-new_dawn_uat\backend\de.metas.rfq\src\main\java-gen\de\metas\rfq\model\X_C_RfQResponse.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public void setPort(int port) {
this.port = port;
}
/**
* Optional root suffix for the embedded LDAP server. Default is
* "dc=springframework,dc=org".
* @param root root suffix for the embedded LDAP server
*/
public void setRoot(String root) {
this.root = root;
}
/**
* Username (DN) of the "manager... | contextSourceFromProviderUrl.afterPropertiesSet();
return contextSourceFromProviderUrl;
}
@Override
public Class<?> getObjectType() {
return DefaultSpringSecurityContextSource.class;
}
@Override
public void destroy() {
if (this.container instanceof Lifecycle) {
((Lifecycle) this.container).stop();
}
... | repos\spring-security-main\config\src\main\java\org\springframework\security\config\ldap\EmbeddedLdapServerContextSourceFactoryBean.java | 2 |
请完成以下Java代码 | public String getId() {
return id;
}
/**
* Sets the value of the id property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setId(String value) {
this.id = value;
}
/**
* Gets the value of the issr prop... | * allowed object is
* {@link String }
*
*/
public void setIssr(String value) {
this.issr = value;
}
/**
* Gets the value of the schmeNm property.
*
* @return
* possible object is
* {@link String }
*
*/
public String ge... | repos\metasfresh-new_dawn_uat\backend\de.metas.banking\de.metas.banking.camt53\src\main\java-xjc\de\metas\banking\camt53\jaxb\camt053_001_04\GenericIdentification20.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public String getProvince() {
return province;
}
/** 银行卡开户所在省 **/
public void setProvince(String province) {
this.province = province;
}
/** 银行卡开户所在城市 **/
public String getCity() {
return city;
}
/** 银行卡开户所在城市 **/
public void setCity(String city) {
this.city = city;
}
/** 银行卡开户所在区 **/
public Str... | /** 证件类型 **/
public void setCardType(String cardType) {
this.cardType = cardType;
}
/** 证件号码 **/
public String getCardNo() {
return cardNo;
}
/** 证件号码 **/
public void setCardNo(String cardNo) {
this.cardNo = cardNo;
}
/** 手机号码 **/
public String getMobileNo() {
return mobileNo;
}
/** 手机号码 **/
pu... | repos\roncoo-pay-master\roncoo-pay-service\src\main\java\com\roncoo\pay\user\entity\RpUserBankAccount.java | 2 |
请完成以下Java代码 | private AdempiereServer[] getInActive()
{
final List<AdempiereServer> list = new ArrayList<>();
for (int i = 0; i < m_servers.size(); i++)
{
final AdempiereServer server = m_servers.get(i);
if (server != null && (!server.isAlive() || !server.isInterrupted()))
{
list.add(server);
}
}
Adempiere... | /**
* Get Description
*
* @return description
*/
public String getDescription()
{
return "1.4";
} // getDescription
/**
* Get Number Servers
*
* @return no of servers
*/
public String getServerCount()
{
int noRunning = 0;
int noStopped = 0;
for (int i = 0; i < m_servers.size(); i++)
{
... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\serverRoot\de.metas.adempiere.adempiere.serverRoot.base\src\main\java-legacy\org\compiere\server\AdempiereServerMgr.java | 1 |
请完成以下Java代码 | public Builder setParameters(@NonNull final Map<String, Object> parameters)
{
parameters.forEach(this::setParameter);
return this;
}
private ImmutableMap<String, Object> getParameters()
{
return parameters != null ? ImmutableMap.copyOf(parameters) : ImmutableMap.of();
}
public Builder applySecuri... | this.jsonFilters = jsonFilters;
this.filters = filters;
}
/**
* empty constructor
*/
private WrappedDocumentFilterList()
{
filters = DocumentFilterList.EMPTY;
jsonFilters = null;
}
public DocumentFilterList unwrap(final DocumentFilterDescriptorsProvider descriptors)
{
if (filters != nu... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\view\CreateViewRequest.java | 1 |
请完成以下Java代码 | public JsonResolveLocatorResponse resolveLocator(@RequestBody @NonNull final JsonResolveLocatorRequest request)
{
assertApplicationAccess();
final LocatorScannedCodeResolverResult result = jobService.resolveLocator(
request.getScannedCode(),
request.getWfProcessId(),
request.getLineId(),
Env.getLo... | return workflowRestController.toJson(WFProcessMapper.toWFProcess(inventory));
}
@GetMapping("/lineHU")
public JsonInventoryLineHU getLineHU(
@RequestParam("wfProcessId") @NonNull String wfProcessIdStr,
@RequestParam("lineId") @NonNull String lineIdStr,
@RequestParam("lineHUId") @NonNull String lineHUIdStr)... | repos\metasfresh-new_dawn_uat\backend\de.metas.inventory.mobileui\src\main\java\de\metas\inventory\mobileui\rest_api\InventoryRestController.java | 1 |
请在Spring Boot框架中完成以下Java代码 | public String getVersionTag() {
return versionTag;
}
public Integer getHistoryTimeToLive() {
return historyTimeToLive;
}
public boolean isStartableInTasklist() {
return isStartableInTasklist;
}
public static ProcessDefinitionDto fromProcessDefinition(ProcessDefinition definition) {
Proces... | dto.description = definition.getDescription();
dto.name = definition.getName();
dto.version = definition.getVersion();
dto.resource = definition.getResourceName();
dto.deploymentId = definition.getDeploymentId();
dto.diagram = definition.getDiagramResourceName();
dto.suspended = definition.isSus... | repos\camunda-bpm-platform-master\engine-rest\engine-rest\src\main\java\org\camunda\bpm\engine\rest\dto\repository\ProcessDefinitionDto.java | 2 |
请完成以下Java代码 | public String getNormalName() {
return "Entity View";
}
},
WIDGETS_BUNDLE(16),
WIDGET_TYPE(17),
TENANT_PROFILE(20),
DEVICE_PROFILE(21),
ASSET_PROFILE(22),
API_USAGE_STATE(23),
TB_RESOURCE(24, "resource"),
OTA_PACKAGE(25),
EDGE(26),
RPC(27),
QUEUE(28),
... | this.tableName = name().toLowerCase();
}
EntityType(int protoNumber, String tableName) {
this.protoNumber = protoNumber;
this.tableName = tableName;
}
public boolean isOneOf(EntityType... types) {
if (types == null) {
return false;
}
for (EntityType ... | repos\thingsboard-master\common\data\src\main\java\org\thingsboard\server\common\data\EntityType.java | 1 |
请在Spring Boot框架中完成以下Java代码 | private Optional<I_S_PostgREST_Config> getOptionalConfigRecordFor(@NonNull final OrgId orgId)
{
return cache.getOrLoad(orgId, this::retrieveConfigFor);
}
@NonNull
private Optional<I_S_PostgREST_Config> retrieveConfigFor(@NonNull final OrgId orgId)
{
return queryBL
.createQueryBuilder(I_S_PostgREST_Config.... | if (postgRESTConfig.getConnectionTimeout() == null)
{
configRecord.setConnection_timeout(0);
}
else
{
final long millis = postgRESTConfig.getConnectionTimeout().toMillis();
configRecord.setConnection_timeout((int)millis);
}
if (postgRESTConfig.getReadTimeout() == null)
{
configRecord.setRead_t... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\postgrest\config\PostgRESTConfigRepository.java | 2 |
请在Spring Boot框架中完成以下Java代码 | private static RootBeanDefinition getMapper(String userDetailsClass) {
if (OPT_PERSON.equals(userDetailsClass)) {
return new RootBeanDefinition(PERSON_MAPPER_CLASS, null, null);
}
if (OPT_INETORGPERSON.equals(userDetailsClass)) {
return new RootBeanDefinition(INET_ORG_PERSON_MAPPER_CLASS, null, null);
}
... | populator.addConstructorArgValue(parseServerReference(elt, parserContext));
populator.addConstructorArgValue(groupSearchBase);
populator.addPropertyValue("groupSearchFilter", groupSearchFilter);
populator.addPropertyValue("searchSubtree", Boolean.TRUE);
if (StringUtils.hasText(rolePrefix)) {
if ("none".equal... | repos\spring-security-main\config\src\main\java\org\springframework\security\config\ldap\LdapUserServiceBeanDefinitionParser.java | 2 |
请完成以下Java代码 | void logToSystemErr(String message, Object... args) {
if (isSystemErrLoggingEnabled()) {
message = message.trim().endsWith("%n") ? message : message.concat("%n");
System.err.printf(message, args);
System.err.flush();
}
}
private boolean isSystemErrLoggingEnabled() {
return Optional.ofNullable(thread... | logProperties(Arrays.asList(propertyNames), enumerablePropertySource::getProperty);
}
return propertySource;
}
}
// The PropertySource may not be enumerable but may use a Map as its source.
protected class MapPropertySourceLoggingFunction extends AbstractPropertySourceLoggingFunction {
@Override
@Supp... | repos\spring-boot-data-geode-main\spring-geode-project\spring-geode\src\main\java\org\springframework\geode\context\logging\EnvironmentLoggingApplicationListener.java | 1 |
请完成以下Java代码 | public static QuickInputLayoutDescriptor build(@NonNull final DocumentEntityDescriptor entityDescriptor, @NonNull final String[][] fieldNames) {return onlyFields(entityDescriptor, fieldNames);}
public static QuickInputLayoutDescriptor onlyFields(
@NonNull final DocumentEntityDescriptor entityDescriptor,
@NonNul... | }
@Override
public String toString()
{
return MoreObjects.toStringHelper(this)
.omitNullValues()
.add("elements", elements.isEmpty() ? null : elements)
.toString();
}
public List<DocumentLayoutElementDescriptor> getElements()
{
return elements;
}
public static final class Builder
{
private... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\quickinput\QuickInputLayoutDescriptor.java | 1 |
请完成以下Java代码 | public String getProcessDefinitionId() {
return processDefinitionId;
}
public void setProcessDefinitionId(String processDefinitionId) {
this.processDefinitionId = processDefinitionId;
}
public String getProcessDefinitionName() {
return processDefinitionName;
}
public v... | extraInfoAlreadyPresent = true;
}
if (processDefinitionName != null) {
if (extraInfoAlreadyPresent) {
strb.append(" | ");
}
strb.append("processDefinitionName = ").append(processDefinitionName).append(" | ");
extraInfoAlreadyPresent = true;... | repos\flowable-engine-main\modules\flowable-process-validation\src\main\java\org\flowable\validation\ValidationError.java | 1 |
请完成以下Java代码 | private void runSimulation(int numWorkers, int numberOfPartialResults) {
NUM_PARTIAL_RESULTS = numberOfPartialResults;
NUM_WORKERS = numWorkers;
cyclicBarrier = new CyclicBarrier(NUM_WORKERS, new AggregatorThread());
System.out.println("Spawning " + NUM_WORKERS + " worker threads to com... | System.out.print("Adding ");
for (Integer partialResult : threadResult) {
System.out.print(partialResult + " ");
sum += partialResult;
}
System.out.println();
}
System.out.println(Thread.currentThread().getNa... | repos\tutorials-master\core-java-modules\core-java-concurrency-advanced-7\src\main\java\com\baeldung\cyclicbarrier\CyclicBarrierDemo.java | 1 |
请完成以下Java代码 | public static QtyToDeliverMap ofMap(final Map<ShipmentScheduleId, StockQtyAndUOMQty> map)
{
return map.isEmpty() ? EMPTY : new QtyToDeliverMap(ImmutableMap.copyOf(map));
}
public static QtyToDeliverMap of(@NonNull final ShipmentScheduleId shipmentScheduleId, @NonNull StockQtyAndUOMQty qtyToDeliver)
{
return of... | try
{
return JsonObjectMapperHolder.sharedJsonObjectMapper().writeValueAsString(this);
}
catch (JsonProcessingException e)
{
throw new AdempiereException("Failed serializing " + this, e);
}
}
public boolean isEmpty() {return map.isEmpty();}
public ImmutableSet<ShipmentScheduleId> getShipmentSchedul... | repos\metasfresh-new_dawn_uat\backend\de.metas.handlingunits.base\src\main\java\de\metas\handlingunits\shipmentschedule\api\QtyToDeliverMap.java | 1 |
请完成以下Java代码 | protected int get_AccessLevel()
{
return accessLevel.intValue();
}
/** Load Meta Data */
protected POInfo initPO (Properties ctx)
{
POInfo poi = POInfo.getPOInfo (ctx, Table_ID, get_TrxName());
return poi;
}
public String toString()
{
StringBuffer sb = new Strin... | */
public void setName (String Name)
{
set_Value (COLUMNNAME_Name, Name);
}
/** Get Name.
@return Alphanumeric identifier of the entity
*/
public String getName ()
{
return (String)get_Value(COLUMNNAME_Name);
}
/** Get Record ID/ColumnName
@return ID/ColumnName pair
*/
public Ke... | repos\metasfresh-new_dawn_uat\backend\de.metas.banking\de.metas.banking.base\src\main\java-gen\org\compiere\model\X_C_BankStatementMatcher.java | 1 |
请完成以下Java代码 | public class Product {
@Id
private String id;
private String name;
private String category;
private double price;
private boolean available;
public Product() {
}
public Product(String name, double price, String category, boolean available) {
this.name = name;
this... | this.name = name;
}
public String getCategory() {
return category;
}
public void setCategory(String category) {
this.category = category;
}
public double getPrice() {
return price;
}
public void setPrice(double price) {
this.price = price;
}
p... | repos\tutorials-master\persistence-modules\spring-data-mongodb-2\src\main\java\com\baeldung\multicriteria\Product.java | 1 |
请完成以下Java代码 | public void setIsInternal (boolean IsInternal)
{
set_Value (COLUMNNAME_IsInternal, Boolean.valueOf(IsInternal));
}
/** Get Internal.
@return Internal Organization
*/
public boolean isInternal ()
{
Object oo = get_Value(COLUMNNAME_IsInternal);
if (oo != null)
{
if (oo instanceof Boolean)
r... | @return ID/ColumnName pair
*/
public KeyNamePair getKeyNamePair()
{
return new KeyNamePair(get_ID(), getName());
}
/** Set Valid to.
@param ValidTo
Valid to including this date (last day)
*/
public void setValidTo (Timestamp ValidTo)
{
set_Value (COLUMNNAME_ValidTo, ValidTo);
}... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_B_Seller.java | 1 |
请完成以下Java代码 | public String getComentTmp() {
return comentTmp;
}
public void setComentTmp(String comentTmp) {
this.comentTmp = comentTmp;
}
public List<String> getComment() {
return comment;
}
public void setComment(List<String> comment) {
this.comment = comment;
}
public String getUrl() {
return url;
}
publ... | public String getUrlMd5() {
return urlMd5;
}
public void setUrlMd5(String urlMd5) {
this.urlMd5 = urlMd5;
}
@Override
public String toString() {
return "Blog{" + "title='" + title + '\'' + ", publishDate=" + publishDate + ", readCountStr='" + readCountStr
+ '\'' + ", readCount=" + readCount + ", conten... | repos\spring-boot-quick-master\quick-vw-crawler\src\main\java\com\crawler\vw\entity\Blog.java | 1 |
请完成以下Java代码 | public Q patch() {
return method(HttpPatch.METHOD_NAME);
}
public Q head() {
return method(HttpHead.METHOD_NAME);
}
public Q options() {
return method(HttpOptions.METHOD_NAME);
}
public Q trace() {
return method(HttpTrace.METHOD_NAME);
}
public Map<String, Object> getConfigOptions()... | return null;
}
@SuppressWarnings("unchecked")
public Q configOption(String field, Object value) {
if (field == null || field.isEmpty() || value == null) {
LOG.ignoreConfig(field, value);
} else {
Map<String, Object> config = getConfigOptions();
if (config == null) {
config = ne... | repos\camunda-bpm-platform-master\connect\http-client\src\main\java\org\camunda\connect\httpclient\impl\AbstractHttpRequest.java | 1 |
请完成以下Java代码 | private void validateOneIdentificationMethod(@NonNull final JsonCreateReceiptInfo createReceiptInfo)
{
if (createReceiptInfo.countIdentificationMethods() != 1)
{
throw new AdempiereException(ERR_RECEIPT_SCHEDULE_INVALID_IDENTIFICATION_METHOD)
.appendParametersToMessage()
.setParameter("jsonCreateRecei... | }
private I_M_ReceiptSchedule getById(@NonNull final ReceiptScheduleId receiptScheduleId)
{
return this.receiptScheduleHashMap.computeIfAbsent(receiptScheduleId, receiptScheduleDAO::getById);
}
private List<I_M_ReceiptSchedule> getByIds(@NonNull final ImmutableSet<ReceiptScheduleId> receiptScheduleIds)
{... | repos\metasfresh-new_dawn_uat\backend\de.metas.business.rest-api-impl\src\main\java\de\metas\rest_api\receipt\ReceiptService.java | 1 |
请完成以下Spring Boot application配置 | spring:
application:
name: user-service # 服务名
# Zipkin 配置项,对应 ZipkinProperties 类
zipkin:
base-url: http://127.0.0.1:9411 # Zipkin 服务的地址
# Spring Cloud Sleuth 配置项
sleuth:
# Spring Cloud Sleuth 针对 Web 组件的配置项,例如说 SpringMVC
web:
enabled: true # 是否开启,默认为 true
data:
# MongoDB 配置项,对应 M... | godb:
host: 127.0.0.1
port: 27017
database: yourdatabase
username: test01
password: password01
# 上述属性,也可以只配置 uri | repos\SpringBoot-Labs-master\labx-13\labx-13-sc-sleuth-db-mongodb\src\main\resources\application.yml | 2 |
请完成以下Java代码 | class AnnotatedColumnControlButton extends ColumnControlButton
{
private static final long serialVersionUID = 1L;
public static final String PROPERTY_DisableColumnControl = AnnotatedColumnControlButton.class.getName() + ".DisableColumnControl";
public AnnotatedColumnControlButton(JXTable table)
{
super(table);
... | private static final boolean canControlColumn(TableColumn column)
{
if (!(column instanceof TableColumnExt))
{
return false;
}
final TableColumnExt columnExt = (TableColumnExt)column;
final Object disableColumnControlObj = columnExt.getClientProperty(PROPERTY_DisableColumnControl);
if (DisplayType.toBo... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\client\src\main\java\org\compiere\swing\table\AnnotatedColumnControlButton.java | 1 |
请完成以下Java代码 | public KeyNamePair getKeyNamePair()
{
return new KeyNamePair(get_ID(), getName());
}
public I_AD_User getSalesRep() throws RuntimeException
{
return (I_AD_User)MTable.get(getCtx(), I_AD_User.Table_Name)
.getPO(getSalesRep_ID(), get_TrxName()); }
/** Set Sales Representative.
@param Sales... | return ii.intValue();
}
/** 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 format required - must be unique
... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_C_SalesRegion.java | 1 |
请完成以下Java代码 | public final class ImmutablePair<LT, RT> implements IPair<LT, RT>
{
/**
* Creates an immutable pair
*/
public static <L, R> ImmutablePair<L, R> of(
@Nullable final L left,
@Nullable final R right)
{
return new ImmutablePair<L, R>(left, right);
}
private final LT left;
private final RT right;
privat... | {
if (other.left != null)
return false;
}
else if (!left.equals(other.left))
return false;
if (right == null)
{
if (other.right != null)
return false;
}
else if (!right.equals(other.right))
return false;
return true;
}
@Override
public LT getLeft()
{
return left;
}
@Override
... | repos\metasfresh-new_dawn_uat\misc\de-metas-common\de-metas-common-util\src\main\java\de\metas\common\util\pair\ImmutablePair.java | 1 |
请完成以下Java代码 | public class LocalDateTimeType implements VariableType {
public String getTypeName() {
return "localDateTime";
}
public boolean isCachable() {
return true;
}
public boolean isAbleToStore(Object value) {
if (value == null) {
return true;
}
return... | public Object getValue(ValueFields valueFields) {
Long longValue = valueFields.getLongValue();
if (longValue != null) {
return LocalDateTime.ofEpochSecond(longValue, 0, ZoneOffset.UTC);
}
return null;
}
public void setValue(Object value, ValueFields valueFields) {
... | repos\Activiti-develop\activiti-core\activiti-engine\src\main\java\org\activiti\engine\impl\variable\LocalDateTimeType.java | 1 |
请完成以下Java代码 | public Criteria andBigPicNotIn(List<String> values) {
addCriterion("big_pic not in", values, "bigPic");
return (Criteria) this;
}
public Criteria andBigPicBetween(String value1, String value2) {
addCriterion("big_pic between", value1, value2, "bigPic");
r... | protected Criterion(String condition) {
super();
this.condition = condition;
this.typeHandler = null;
this.noValue = true;
}
protected Criterion(String condition, Object value, String typeHandler) {
super();
this.condition = condit... | repos\mall-master\mall-mbg\src\main\java\com\macro\mall\model\PmsBrandExample.java | 1 |
请完成以下Java代码 | public void sendWebsocketViewChangedNotification(
@RequestParam("viewId") final String viewIdStr,
@RequestParam("changedIds") final String changedIdsStr)
{
assertLoggedIn();
final ViewId viewId = ViewId.ofViewIdString(viewIdStr);
final DocumentIdsSelection changedRowIds = DocumentIdsSelection.ofCommaSepar... | public List<WebsocketEventLogRecord> getWebsocketLoggedEvents(
@RequestParam(value = "destinationFilter", required = false) final String destinationFilter)
{
userSession.assertLoggedIn();
return websocketSender.getLoggedEvents(destinationFilter);
}
@GetMapping("/activeSubscriptions")
public Map<String, ?> ... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\debug\DebugWebsocketRestController.java | 1 |
请完成以下Java代码 | protected ExecutionEntity getProcessInstanceEntity(CommandContext commandContext, String processInstanceId) {
ExecutionEntity processInstance = CommandContextUtil.getExecutionEntityManager(commandContext).findById(processInstanceId);
if (processInstance == null) {
throw new FlowableIllegalAr... | * @param identityType the type of identity link (e.g. owner or assignee, etc)
*/
protected void createIdentityLinkType(CommandContext commandContext, String processInstanceId, String userId, String groupId, String identityType) {
// if both user and group ids are null, don't create an identity link
... | repos\flowable-engine-main\modules\flowable-engine\src\main\java\org\flowable\engine\impl\cmd\AbstractProcessInstanceIdentityLinkCmd.java | 1 |
请完成以下Java代码 | public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public String getUserId() {
return userId;
}
public void setUserId(String userId) {
this.userId = userId;
}
public String getKey() {
return key;
}
public void setKey(Strin... | public void setPassword(String password) {
this.password = password;
}
public String getName() {
return key;
}
public String getUsername() {
return value;
}
public String getParentId() {
return parentId;
}
public void setParentId(String parentId) {
this.parentId = parentId;
}
... | repos\camunda-bpm-platform-master\engine\src\main\java\org\camunda\bpm\engine\impl\persistence\entity\IdentityInfoEntity.java | 1 |
请完成以下Java代码 | public static StringDictionary load(String path, String separator)
{
StringDictionary dictionary = new StringDictionary(separator);
if (dictionary.load(path)) return dictionary;
return null;
}
/**
* 加载词典
* @param path
* @return
*/
public static StringDictiona... | return mainDictionary;
}
public static StringDictionary combine(String... args)
{
String[] pathArray = args.clone();
List<StringDictionary> dictionaryList = new LinkedList<StringDictionary>();
for (String path : pathArray)
{
StringDictionary dictionary = load(pat... | repos\springboot-demo-master\hanlp\src\main\java\demo\hankcs\hanlp\corpus\dictionary\StringDictionaryMaker.java | 1 |
请完成以下Java代码 | public void setRedo (java.lang.String Redo)
{
set_Value (COLUMNNAME_Redo, Redo);
}
/** Get Redo.
@return Redo */
@Override
public java.lang.String getRedo ()
{
return (java.lang.String)get_Value(COLUMNNAME_Redo);
}
/** Set Transaktion.
@param TrxName
Name of the transaction
*/
@Override
pub... | @Override
public java.lang.String getTrxName ()
{
return (java.lang.String)get_Value(COLUMNNAME_TrxName);
}
/** Set Undo.
@param Undo Undo */
@Override
public void setUndo (java.lang.String Undo)
{
set_Value (COLUMNNAME_Undo, Undo);
}
/** Get Undo.
@return Undo */
@Override
public java.lang.St... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_AD_ChangeLog.java | 1 |
请完成以下Java代码 | public class OnlyOneOpenInvoiceCandProcessor implements IShipmentSchedulesAfterFirstPassUpdater
{
public static final String MSG_OPEN_INVOICE_1P = "ShipmentSchedule_OpenInvoice_1P";
public static final String MSG_WITH_NEXT_SUBSCRIPTION = "ShipmentSchedule_WithNextSubscription";
private static final Logger logger =... | {
final BPartnerStats stats = Services.get(IBPartnerStatsDAO.class).getCreateBPartnerStats(lineCandidate.getBillBPartnerId());
final String creditStatus = I_C_BPartner.SO_CREDITSTATUS_ONE_OPEN_INVOICE;
if (creditStatus.equals(stats.getSOCreditStatus()))
{
final BigDecimal soCreditUsed = stats.getSOCred... | repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\inoutcandidate\spi\impl\OnlyOneOpenInvoiceCandProcessor.java | 1 |
请完成以下Java代码 | public CorporateAction1 getCorpActn() {
return corpActn;
}
/**
* Sets the value of the corpActn property.
*
* @param value
* allowed object is
* {@link CorporateAction1 }
*
*/
public void setCorpActn(CorporateAction1 value) {
this.corpActn = ... | * allowed object is
* {@link CashAccount16 }
*
*/
public void setSfkpgAcct(CashAccount16 value) {
this.sfkpgAcct = value;
}
/**
* Gets the value of the addtlTxInf property.
*
* @return
* possible object is
* {@link String }
*
... | 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\EntryTransaction2.java | 1 |
请完成以下Java代码 | public class MessageThrowingEventListener extends BaseDelegateEventListener {
protected String messageName;
protected Class<?> entityClass;
@Override
public void onEvent(FlowableEvent event) {
if (isValidEvent(event) && event instanceof FlowableEngineEvent) {
FlowableEngineEvent en... | }
for (EventSubscriptionEntity signalEventSubscriptionEntity : subscriptionEntities) {
signalEventSubscriptionEntity.eventReceived(null, false);
}
}
}
public void setMessageName(String messageName) {
this.messageName = messageName;
}
@Override
... | repos\flowable-engine-main\modules\flowable5-engine\src\main\java\org\activiti\engine\impl\bpmn\helper\MessageThrowingEventListener.java | 1 |
请完成以下Java代码 | public JSONDocumentField setDisplayed(final boolean displayed)
{
setDisplayed(displayed, null);
return this;
}
/* package */ void setLookupValuesStale(final boolean lookupValuesStale, @Nullable final String reason)
{
this.lookupValuesStale = lookupValuesStale;
lookupValuesStaleReason = reason;
}
/* pack... | {
putDebugProperty(e.getKey(), e.getValue());
}
}
public JSONDocumentField setViewEditorRenderMode(final ViewEditorRenderMode viewEditorRenderMode)
{
this.viewEditorRenderMode = viewEditorRenderMode != null ? viewEditorRenderMode.toJson() : null;
return this;
}
public void setFieldWarning(@Nullable fina... | repos\metasfresh-new_dawn_uat\backend\de.metas.ui.web.base\src\main\java\de\metas\ui\web\window\datatypes\json\JSONDocumentField.java | 1 |
请完成以下Java代码 | public void reset() {
this.delegate.reset();
}
@Override
public void restore(Object previousValue) {
restoreInternal(previousValue);
}
@SuppressWarnings("unchecked")
public <V> void restoreInternal(Object previousValue) {
((ThreadLocalAccessor<V>) this.delegate).restore((V) previousValue);
}
@Override
... | }
private static final class NoOpAccessor implements ThreadLocalAccessor<Object> {
@Override
public Object key() {
return getClass().getName();
}
@Override
public @Nullable Object getValue() {
return null;
}
@Override
public void setValue(Object value) {
}
@Override
public void setVal... | repos\spring-graphql-main\spring-graphql\src\main\java\org\springframework\graphql\execution\SecurityContextThreadLocalAccessor.java | 1 |
请完成以下Java代码 | public String toString()
{
return ObjectUtils.toString(this);
}
@Override
public I_C_Invoice_Candidate getC_Invoice_Candidate()
{
return invoiceCandidate;
}
@Override
public I_C_InvoiceCandidate_InOutLine getC_InvoiceCandidate_InOutLine()
{
return iciol;
}
@Override
public List<Object> getLineAggre... | public String toString()
{
return ObjectUtils.toString(this);
}
public Builder setC_Invoice_Candidate(final I_C_Invoice_Candidate invoiceCandidate)
{
this.invoiceCandidate = invoiceCandidate;
return this;
}
public Builder setC_InvoiceCandidate_InOutLine(final I_C_InvoiceCandidate_InOutLine iciol)... | repos\metasfresh-new_dawn_uat\backend\de.metas.swat\de.metas.swat.base\src\main\java\de\metas\invoicecandidate\api\impl\InvoiceLineAggregationRequest.java | 1 |
请完成以下Java代码 | private ImpDataCell createDateCell(final ImpFormatColumn column, final List<String> cellRawValues)
{
try
{
final String rawValue = extractRawValue(column, cellRawValues);
final Object value = column.parseCellValue(rawValue);
return ImpDataCell.value(value);
}
catch (final Exception ex)
{
return I... | {
inQuotes = false;
doubleQuotesInColumn = false;
}
else
{
// Fixed : allow "" in custom quote enclosed
if (ch == '\"')
{
if (!doubleQuotesInColumn)
{
currentValue.append(ch);
doubleQuotesInColumn = true;
}
}
else
{
currentValue.... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java\de\metas\impexp\parser\FlexImpDataLineParser.java | 1 |
请完成以下Java代码 | protected void executeParse(BpmnParse bpmnParse, SubProcess subProcess) {
ActivityImpl activity = createActivityOnScope(bpmnParse, subProcess, BpmnXMLConstants.ELEMENT_SUBPROCESS, bpmnParse.getCurrentScope());
activity.setAsync(subProcess.isAsynchronous());
activity.setExclusive(!subProcess.is... | bpmnParse.processFlowElements(subProcess.getFlowElements());
processArtifacts(bpmnParse, subProcess.getArtifacts(), activity);
// no data objects for event subprocesses
if (!(subProcess instanceof EventSubProcess)) {
// parse out any data objects from the template in order to set up... | repos\flowable-engine-main\modules\flowable5-engine\src\main\java\org\activiti\engine\impl\bpmn\parser\handler\SubProcessParseHandler.java | 1 |
请完成以下Java代码 | protected boolean beforeSave(boolean newRecord)
{
// Reset Stocked if not Item
// AZ Goodwill: Bug Fix isStocked always return false
// if (isStocked() && !PRODUCTTYPE_Item.equals(getProductType()))
if (!PRODUCTTYPE_Item.equals(getProductType()))
{
setIsStocked(false);
}
// UOM reset
if (m_precisio... | {
insert_Accounting(I_M_Product_Acct.Table_Name,
I_M_Product_Category_Acct.Table_Name,
"p.M_Product_Category_ID=" + getM_Product_Category_ID());
}
else
{
log.info("This M_Product is created via CopyRecordSupport; -> don't insert the default _acct records");
}
insert_Tree(X_AD_... | repos\metasfresh-new_dawn_uat\backend\de.metas.business\src\main\java-legacy\org\compiere\model\MProduct.java | 1 |
请完成以下Java代码 | public java.lang.String getProductDescription()
{
return get_ValueAsString(COLUMNNAME_ProductDescription);
}
@Override
public void setProductName (final @Nullable java.lang.String ProductName)
{
set_Value (COLUMNNAME_ProductName, ProductName);
}
@Override
public java.lang.String getProductName()
{
re... | public void setUPC (final @Nullable java.lang.String UPC)
{
set_Value (COLUMNNAME_UPC, UPC);
}
@Override
public java.lang.String getUPC()
{
return get_ValueAsString(COLUMNNAME_UPC);
}
@Override
public void setUsedForCustomer (final boolean UsedForCustomer)
{
set_Value (COLUMNNAME_UsedForCustomer, Used... | repos\metasfresh-new_dawn_uat\backend\de.metas.adempiere.adempiere\base\src\main\java-gen\org\compiere\model\X_C_BPartner_Product.java | 1 |
请完成以下Java代码 | private void enqueueShipmentsForDesadv(
final @NonNull IWorkPackageQueue queue,
final @NonNull I_EDI_Desadv desadv)
{
final List<I_M_InOut> shipments = desadvDAO.retrieveShipmentsWithStatus(desadv, ImmutableSet.of(EDIExportStatus.Pending, EDIExportStatus.Error));
final String trxName = InterfaceWrapperHelper... | private Iterator<I_EDI_Desadv> createIterator()
{
final IQueryBuilder<I_EDI_Desadv> queryBuilder = queryBL.createQueryBuilder(I_EDI_Desadv.class, getCtx(), get_TrxName())
.addOnlyActiveRecordsFilter()
.filter(getProcessInfo().getQueryFilterOrElseFalse());
queryBuilder.orderBy()
.addColumn(I_EDI_Desadv... | repos\metasfresh-new_dawn_uat\backend\de.metas.edi\src\main\java\de\metas\edi\process\EDI_Desadv_InOut_EnqueueForExport.java | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.