X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.structural2%2Fsrc%2Forg%2Fsimantics%2Fstructural2%2FmodelingRules%2FIModelingRules.java;fp=bundles%2Forg.simantics.structural2%2Fsrc%2Forg%2Fsimantics%2Fstructural2%2FmodelingRules%2FIModelingRules.java;h=40183cff5809e9ee8e0cee5e1ec8e74ecb247f46;hp=39cf28e12abf77d2a9a65b800fa61ec890440b92;hb=0ae2b770234dfc3cbb18bd38f324125cf0faca07;hpb=24e2b34260f219f0d1644ca7a138894980e25b14 diff --git a/bundles/org.simantics.structural2/src/org/simantics/structural2/modelingRules/IModelingRules.java b/bundles/org.simantics.structural2/src/org/simantics/structural2/modelingRules/IModelingRules.java index 39cf28e12..40183cff5 100644 --- a/bundles/org.simantics.structural2/src/org/simantics/structural2/modelingRules/IModelingRules.java +++ b/bundles/org.simantics.structural2/src/org/simantics/structural2/modelingRules/IModelingRules.java @@ -1,70 +1,70 @@ -/******************************************************************************* - * Copyright (c) 2007, 2010 Association for Decentralized Information Management - * in Industry THTH ry. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * VTT Technical Research Centre of Finland - initial API and implementation - *******************************************************************************/ -package org.simantics.structural2.modelingRules; - -import java.util.Collection; -import java.util.Set; - -import org.simantics.db.ReadGraph; -import org.simantics.db.Resource; -import org.simantics.db.WriteGraph; -import org.simantics.db.exception.DatabaseException; - -/** - * @see Ontology documentation - * @author Hannu Niemistö - */ -public interface IModelingRules { - /** - * Returns true if the component type can be populated to the diagram. - */ - boolean canPopulate(ReadGraph g, - Resource componentType) throws DatabaseException; - - /** - * Tells if connecting the given connection points is possible - * and what the connection type would be. - */ - ConnectionJudgement judgeConnection(ReadGraph g, - Collection connectionPoints) - throws DatabaseException; - - /** - * Computes a connection type the the given connection - */ - Resource computeConnectionType(ReadGraph g, - Collection connectionPoints) - throws DatabaseException; - - /** - * Gets attachment relations of already existing connection. - */ - IAttachmentRelationMap getAttachmentRelations(ReadGraph g, - Resource connection) throws DatabaseException; - - /** - * Writes the connection type of the connection to graph. - */ - void setConnectionType(WriteGraph g, - Resource connection, - Resource connectionType) throws DatabaseException; - - /** - * Reads the connection type of the connection. - */ - Resource getConnectionType(ReadGraph g, - Resource connection) throws DatabaseException; - - Set resolveTerminals(ReadGraph g, - Collection connectionPoints) throws DatabaseException; - -} +/******************************************************************************* + * Copyright (c) 2007, 2010 Association for Decentralized Information Management + * in Industry THTH ry. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * VTT Technical Research Centre of Finland - initial API and implementation + *******************************************************************************/ +package org.simantics.structural2.modelingRules; + +import java.util.Collection; +import java.util.Set; + +import org.simantics.db.ReadGraph; +import org.simantics.db.Resource; +import org.simantics.db.WriteGraph; +import org.simantics.db.exception.DatabaseException; + +/** + * @see Ontology documentation + * @author Hannu Niemistö + */ +public interface IModelingRules { + /** + * Returns true if the component type can be populated to the diagram. + */ + boolean canPopulate(ReadGraph g, + Resource componentType) throws DatabaseException; + + /** + * Tells if connecting the given connection points is possible + * and what the connection type would be. + */ + ConnectionJudgement judgeConnection(ReadGraph g, + Collection connectionPoints) + throws DatabaseException; + + /** + * Computes a connection type the the given connection + */ + Resource computeConnectionType(ReadGraph g, + Collection connectionPoints) + throws DatabaseException; + + /** + * Gets attachment relations of already existing connection. + */ + IAttachmentRelationMap getAttachmentRelations(ReadGraph g, + Resource connection) throws DatabaseException; + + /** + * Writes the connection type of the connection to graph. + */ + void setConnectionType(WriteGraph g, + Resource connection, + Resource connectionType) throws DatabaseException; + + /** + * Reads the connection type of the connection. + */ + Resource getConnectionType(ReadGraph g, + Resource connection) throws DatabaseException; + + Set resolveTerminals(ReadGraph g, + Collection connectionPoints) throws DatabaseException; + +}