当前位置: 首页>>代码示例>>Java>>正文


Java Commit类代码示例

本文整理汇总了Java中org.simpleframework.xml.core.Commit的典型用法代码示例。如果您正苦于以下问题:Java Commit类的具体用法?Java Commit怎么用?Java Commit使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Commit类属于org.simpleframework.xml.core包,在下文中一共展示了Commit类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: FixupRecordPersonIds

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
private void FixupRecordPersonIds() {
	for (PersonInfo pi : getPersonInfoList()) {
		String personId = pi.getPersonId();
		
		for (Record r : pi.getRecords()) {
			r.setPersonId(personId);
		}
	}
}
 
开发者ID:Microsoft,项目名称:healthvault-java-sdk,代码行数:11,代码来源:GetAuthorizedPeopleResponseResults.java

示例2: build

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
/**
 * This function is called by SimpleXML after deserialisation in order to
 * recreate the map of equipment cofngiurations from the list.
 */
@Commit
public void build() {
  for (EquipmentConfiguration configuration : equipmentConfigurationList) {
    equipmentConfigurations.put(configuration.getId(), configuration);
  }
}
 
开发者ID:c2mon,项目名称:c2mon,代码行数:11,代码来源:ProcessConfiguration.java

示例3: solveDepencies

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
/**
 * Is responsible for solving dependencies child elements/objects may have on the P-Mode id. Currently this applies
 * to the identification of the delivery specifications included in the P-Mode. Because the Holodeck B2B Core
 * requires each delivery specification to have a unique id to enable reuse each delivery specification included in
 * the P-Mode is given an id combined of the P-Mode id, current time and type of delivery, for example the default
 * delivery specification defined on the Leg will have «P-Mode id»+"-"+«hhmmss» +"-defaultDelivery" as id.
 * <p>The objects containing the {@link DeliverySpecification}s are responsible for including these in the given
 * <code>Map</code> using the type of delivery as key and the object as value.
 *
 * @param dependencies  A <code>Map</code> containing all {@link DeliverySpecification} objects that have to be
 *                      assigned an id. The key of the entry MUST be a <code>String</code> containing the type
 *                      of delivery, e.g. "defaultDelivery".
 */
@Commit
public void solveDepencies(final Map dependencies) {
    if (dependencies == null)
        return;

    for(final Object k : dependencies.keySet()) {
        final Object dep = dependencies.get(k);
        if (k instanceof String && dep != null && dep instanceof DeliverySpecification)
            ((DeliverySpecification) dep).setId(this.pmodeId.id
                                                + "-" + new SimpleDateFormat("HHmmss").format(new Date())
                                                + "-" + k);
    }
}
 
开发者ID:holodeck-b2b,项目名称:Holodeck-B2B,代码行数:27,代码来源:PMode.java

示例4: setDepency

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
/**
 * This method ensures that the {@link DeliverySpecification} for the default delivery method gets an unique id
 * based on the P-Mode id. Because we do not know the P-Mode id here we use the <i>commit</i> functionality of the
 * Simple framework (see <a href="http://simple.sourceforge.net/download/stream/doc/tutorial/tutorial.php#state">
 * http://simple.sourceforge.net/download/stream/doc/tutorial/tutorial.php#state</a>). We put the <code>
 * defaultDelivery</code> object in the deserialization session so {@link PMode#solveDepencies(java.util.Map)} can
 * set the id using the P-Mode id.
 *
 * @param dependencies The Simple session object.
 */
@Commit
public void setDepency(final Map dependencies) {
    if (defaultDelivery != null) {
        // Because multiple DefaultDelivery elements can exist in the P-Mode document when we enable Two-Way MEPs,
        // we make sure it get a unique id
        int i = 0;
        while (dependencies.containsKey("DefaultDelivery-" + i)) i++;
        dependencies.put("DefaultDelivery-"+i, defaultDelivery);
    }
}
 
开发者ID:holodeck-b2b,项目名称:Holodeck-B2B,代码行数:21,代码来源:Leg.java

示例5: setDepency

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
/**
 * This method ensures that the {@link DeliverySpecification} for the receipt delivery method gets an unique id
 * based on the P-Mode id. Because we do not know the P-Mode id here we use the <i>commit</i> functionality of the
 * Simple framework (see <a href="http://simple.sourceforge.net/download/stream/doc/tutorial/tutorial.php#state">
 * http://simple.sourceforge.net/download/stream/doc/tutorial/tutorial.php#state</a>). We put the <code>
 * receiptDelivery</code> object in the deserialization session so {@link PMode#solveDepencies(java.util.Map)} can
 * set the id using the P-Mode id.
 *
 * @param dependencies The Simple session object.
 */
@Commit
public void setDepency(final Map dependencies) {
    if (receiptDelivery != null) {
        // Because multiple ReceiptDelivery elements can exist in the P-Mode document when we enable Two-Way MEPs,
        // we make sure it get a unique id
        int i = 0;
        while (dependencies.containsKey("ReceiptDelivery-" + i)) i++;
        dependencies.put("ReceiptDelivery-"+i, receiptDelivery);
    }
}
 
开发者ID:holodeck-b2b,项目名称:Holodeck-B2B,代码行数:21,代码来源:ReceiptConfiguration.java

示例6: build

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void build() throws PersistenceException {
	for(Behavior behavior : allowedBehaviors) {
		behavior.question = questionMap.get(behavior.questionId);
	}
	
	for(AdditionalInformation ai : additionalInformation) {
		ai.behavior = behaviorMap.get(ai.behaviorId);
	}
	
	super.build();
}
 
开发者ID:Angerona,项目名称:angerona-framework,代码行数:13,代码来源:DefendingSituation.java

示例7: build

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void build() throws PersistenceException {
	try {
		if(filenameBackgroundProgram != null) {
			backgroundKnowledge = ASPParser.parseProgram(new FileReader(filenameBackgroundProgram));
		}
	} catch (FileNotFoundException | ParseException e) {
		throw new PersistenceException("Cannot parse background program in '" + filenameBackgroundProgram + "' - " + e.getMessage());
	}
	
}
 
开发者ID:Angerona,项目名称:angerona-framework,代码行数:12,代码来源:Situation.java

示例8: onDeserialization

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void onDeserialization() {
	AngeronaEnvironment sim = Angerona.getInstance().getActualSimulation();
	if(sim != null) {
		setAgent(sim.getAgentByName(sender));
	}
}
 
开发者ID:Angerona,项目名称:angerona-framework,代码行数:8,代码来源:Action.java

示例9: commit

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void commit() {
	for(AgentInstance ai : agents) {
		for(String viewedAgent : ai.fileViewMap.keySet()) {
			File f = ai.fileViewMap.get(viewedAgent);
			BeliefbaseConfigReal conf = SerializeHelper.get().loadXmlTry(
					BeliefbaseConfigReal.class, f);
			ai.realViewMap.put(viewedAgent, conf);
		}
	}
}
 
开发者ID:Angerona,项目名称:angerona-framework,代码行数:12,代码来源:SimulationConfiguration.java

示例10: createOperationTypes

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
protected void createOperationTypes() {
	// extract operation type from element name...
	((OperationSetConfigReal)reasonerOperators).operationType = BaseReasoner.OPERATION_TYPE;
	((OperationSetConfigReal)changeOperators).operationType = BaseChangeBeliefs.OPERATION_TYPE;
	((OperationSetConfigReal)this.translators).operationType = BaseTranslator.OPERATION_TYPE;
}
 
开发者ID:Angerona,项目名称:angerona-framework,代码行数:8,代码来源:BeliefbaseConfigReal.java

示例11: fixUpInternalThingReference

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
private void fixUpInternalThingReference() {
	dataXml.getAny().setThing(this);
}
 
开发者ID:Microsoft,项目名称:healthvault-java-sdk,代码行数:5,代码来源:Thing2.java

示例12: commit

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void commit(Map map) {
   if(validated) {              
      committed = true;              
   }            
}
 
开发者ID:ngallagher,项目名称:simplexml,代码行数:7,代码来源:ContextualCallbackTest.java

示例13: prepare

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
private void prepare() {
   if(trim) {
      text = text.trim();
   }
}
 
开发者ID:ngallagher,项目名称:simplexml,代码行数:7,代码来源:InjectionTest.java

示例14: commit

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
@Commit
public void commit(Map map) {
   map.put(name, value);              
}
 
开发者ID:ngallagher,项目名称:simplexml,代码行数:5,代码来源:TemplateTest.java

示例15: calculateInterval

import org.simpleframework.xml.core.Commit; //导入依赖的package包/类
/**
 * Is a helper to construct the {@link Interval} object. Uses the commit function of the Simple framework.
 */
@Commit
public void calculateInterval() {
    retryInterval = new Interval(retryIntervalDuration, TimeUnit.SECONDS);
}
 
开发者ID:holodeck-b2b,项目名称:Holodeck-B2B,代码行数:8,代码来源:ReceptionAwareness.java


注:本文中的org.simpleframework.xml.core.Commit类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。