本文整理汇总了Java中org.alfresco.repo.dictionary.M2Model.getImports方法的典型用法代码示例。如果您正苦于以下问题:Java M2Model.getImports方法的具体用法?Java M2Model.getImports怎么用?Java M2Model.getImports使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.alfresco.repo.dictionary.M2Model
的用法示例。
在下文中一共展示了M2Model.getImports方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: loadModel
import org.alfresco.repo.dictionary.M2Model; //导入方法依赖的package包/类
private void loadModel(Map<String, M2Model> modelMap, HashSet<String> loadedModels, M2Model model)
{
String modelName = model.getName();
if (loadedModels.contains(modelName) == false)
{
for (M2Namespace importNamespace : model.getImports())
{
M2Model importedModel = modelMap.get(importNamespace.getUri());
if (importedModel != null)
{
// Ensure that the imported model is loaded first
loadModel(modelMap, loadedModels, importedModel);
}
}
dictionaryDAO.putModelIgnoringConstraints(model);
loadedModels.add(modelName);
}
}
示例2: loadModel
import org.alfresco.repo.dictionary.M2Model; //导入方法依赖的package包/类
private void loadModel(Map<String, M2Model> modelMap, HashSet<String> loadedModels, M2Model model)
{
String modelName = model.getName();
if (loadedModels.contains(modelName) == false)
{
for (M2Namespace importNamespace : model.getImports())
{
M2Model importedModel = modelMap.get(importNamespace.getUri());
if (importedModel != null)
{
// Ensure that the imported model is loaded first
loadModel(modelMap, loadedModels, importedModel);
}
}
if (this.infoSrv.putModel(model))
{
loadedModels.add(modelName);
}
log.info("Loading model " + model.getName());
}
}
示例3: loadModel
import org.alfresco.repo.dictionary.M2Model; //导入方法依赖的package包/类
/**
* Loads a model (and its dependents) if it does not exist in the list of loaded models.
*
* @param modelMap
* a map of the models to be loaded
* @param loadedModels
* the list of models already loaded
* @param model
* the model to try and load
*/
private void loadModel(Map<String, M2Model> modelMap, HashSet<String> loadedModels, M2Model model)
{
String modelName = model.getName();
if (loadedModels.contains(modelName) == false)
{
for (M2Namespace importNamespace : model.getImports())
{
M2Model importedModel = modelMap.get(importNamespace.getUri());
if (importedModel != null)
{
// Ensure that the imported model is loaded first
loadModel(modelMap, loadedModels, importedModel);
}
}
AlfrescoSolrDataModel.getInstance(id).putModel(model);
loadedModels.add(modelName);
}
}
示例4: loadModel
import org.alfresco.repo.dictionary.M2Model; //导入方法依赖的package包/类
private void loadModel(Map<String, M2Model> modelMap, HashSet<String> loadedModels, M2Model model)
{
String modelName = model.getName();
if (loadedModels.contains(modelName) == false)
{
for (M2Namespace importNamespace : model.getImports())
{
M2Model importedModel = modelMap.get(importNamespace.getUri());
if (importedModel != null)
{
// Ensure that the imported model is loaded first
loadModel(modelMap, loadedModels, importedModel);
}
}
if(this.infoSrv.putModel(model))
{
loadedModels.add(modelName);
}
log.info("Loading model " + model.getName());
}
}