X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=org.simantics.plant3d%2Fsrc%2Forg%2Fsimantics%2Fplant3d%2Futils%2FP3DUtil.java;h=42a3b9a0f5277c3ee5aff8d8e09d4790c840cd0f;hb=b2ec2045289a5aa41a2a6804f03890336e220cde;hp=2f5972a8d86a160dd4fd022fd93c605cc2706194;hpb=1f7b0edd896d1a274f1cd7d545d4360993c26c7c;p=simantics%2F3d.git diff --git a/org.simantics.plant3d/src/org/simantics/plant3d/utils/P3DUtil.java b/org.simantics.plant3d/src/org/simantics/plant3d/utils/P3DUtil.java index 2f5972a8..42a3b9a0 100644 --- a/org.simantics.plant3d/src/org/simantics/plant3d/utils/P3DUtil.java +++ b/org.simantics.plant3d/src/org/simantics/plant3d/utils/P3DUtil.java @@ -25,13 +25,21 @@ import org.simantics.plant3d.scenegraph.PipeRun; import org.simantics.plant3d.scenegraph.PipelineComponent; import org.simantics.plant3d.scenegraph.controlpoint.PipeControlPoint; import org.simantics.plant3d.scenegraph.controlpoint.PipingRules; +import org.simantics.plant3d.scl.SCLUtil; import org.simantics.plant3d.utils.Item.Type; public class P3DUtil { + public static List getEquipments() throws DatabaseException { + return getEquipments(SCLUtil.getRequestProcessor()); + } public static List getEquipments(RequestProcessor session) throws DatabaseException { return getEquipments(session, Plant3D.URIs.Builtin); } + + public static List getEquipments(final String libUri) throws DatabaseException { + return getEquipments(SCLUtil.getRequestProcessor(), libUri); + } public static List getEquipments(RequestProcessor session, final String libUri) throws DatabaseException { return session.syncRequest(new Read>() { @@ -49,6 +57,10 @@ public class P3DUtil { }); } + public static List getNozzles(String libUri) throws DatabaseException { + return getNozzles(SCLUtil.getRequestProcessor(), libUri); + } + public static List getNozzles(RequestProcessor session, String libUri) throws DatabaseException { return session.syncRequest(new Read>() { @Override @@ -94,6 +106,10 @@ public class P3DUtil { } } + public static List getEnds(String libUri) throws DatabaseException { + return getEnds(SCLUtil.getRequestProcessor(), libUri); + } + public static List getEnds(RequestProcessor session, String libUri) throws DatabaseException { return session.syncRequest(new Read>() { @Override @@ -104,6 +120,10 @@ public class P3DUtil { } }); } + + public static List getTurns(String libUri) throws DatabaseException { + return getTurns(SCLUtil.getRequestProcessor(), libUri); + } public static List getTurns(RequestProcessor session, String libUri) throws DatabaseException { return session.syncRequest(new Read>() { @@ -115,6 +135,10 @@ public class P3DUtil { } }); } + + public static List getInlines(String libUri) throws DatabaseException { + return getInlines(SCLUtil.getRequestProcessor(), libUri); + } public static List getInlines(RequestProcessor session, String libUri) throws DatabaseException { return session.syncRequest(new Read>() {