use of com.developmentontheedge.be5.metadata.model.Module in project be5 by DevelopmentOnTheEdge.
the class BeModelElementSupport method isAvailable.
@PropertyName("Available in current project")
@Override
public boolean isAvailable() {
if (usedInExtras == null || usedInExtras.length == 0)
return true;
Module module = getModule();
String[] extras = module == null ? Strings2.EMPTY : module.getExtras();
Project project = getProject();
for (String usedInExtra : usedInExtras) {
if (!hasExtra(extras, project, usedInExtra))
return false;
}
return true;
}
use of com.developmentontheedge.be5.metadata.model.Module in project be5 by DevelopmentOnTheEdge.
the class DataElementUtils method moveBackToItsModule.
/**
* Moves the model element back to the its module if the element is an entity item.
*
* @param modelElement
*/
public static void moveBackToItsModule(final BeModelElement modelElement) {
if (modelElement instanceof BeElementWithOriginModule) {
BeElementWithOriginModule r = (BeElementWithOriginModule) modelElement;
r.setOriginModuleName(r.getModule().getName());
}
}
use of com.developmentontheedge.be5.metadata.model.Module in project be5 by DevelopmentOnTheEdge.
the class Serialization method reloadDaemons.
public static Daemons reloadDaemons(final Path file, final Module target) throws ReadException {
checkProject(target.getProject());
turnOffAutomaticSerialization();
try {
return new YamlDeserializer(new LoadContext()).reloadDaemons(file, target);
} finally {
turnOnAutomaticSerialization();
}
}
use of com.developmentontheedge.be5.metadata.model.Module in project be5 by DevelopmentOnTheEdge.
the class Serialization method reloadCustomizations.
public static PageCustomizations reloadCustomizations(final Path file, final Module target) throws ReadException {
checkProject(target.getProject());
turnOffAutomaticSerialization();
try {
return new YamlDeserializer(new LoadContext()).reloadCustomizations(file, target);
} finally {
turnOnAutomaticSerialization();
}
}
use of com.developmentontheedge.be5.metadata.model.Module in project be5 by DevelopmentOnTheEdge.
the class YamlDeserializer method reloadPages.
public StaticPages reloadPages(final Path path, final Module target) throws ReadException {
final StaticPages pages = new StaticPages(target);
final StaticPagesDeserializer deserializer = new StaticPagesDeserializer(path, pages);
deserializer.deserialize();
DataElementUtils.saveQuiet(pages);
return pages;
}
Aggregations