Protege-2000 1.7

edu.stanford.smi.protegex.widget.diagram
Class DiagramUtilities

java.lang.Object
  |
  +--edu.stanford.smi.protegex.widget.diagram.DiagramUtilities
All Implemented Interfaces:
Constants

public class DiagramUtilities
extends Object
implements Constants

Static helper methods for the various bits and pieces of the diagrams package. Mostly dealing with editing the KB.

Author:
William Grosso

Fields inherited from interface edu.stanford.smi.protegex.widget.diagram.Constants
CONFIGURATION_BASED_VISIBILITY_CHECKER, CONNECTOR_CLASS, CONNECTORS_SLOT, DEFAULT_LAST_DIVIDER_LOCATION, DEFAULT_LOWER_BOUND_ON_DIAGRAM_LOGICAL_HEIGHT, DEFAULT_LOWER_BOUND_ON_DIAGRAM_LOGICAL_WIDTH, DEFAULT_NODE_HEIGHT, DEFAULT_NODE_WIDTH, FIRST_OBJECT_SLOT_NAME, FIRST_OBJECT_SLOT_POINTER_NAME, IMAGE_CONTROLPOINT_PRECISION, IMAGE_MINIMUM_SIZE, LAST_DIVIDER_LOCATION, LAYOUT_INFORMATION_SLOT, LOCATION_SLOT, LOWER_RIGHT_CORNER_SLOT, MAIN_SIDE_RECTANGLE_HEIGHT, MAIN_SIDE_RECTANGLE_WIDTH, NETWORK_CLASS, NETWORK_METACLASS, NODE_SLOT, OBJECT_LOCATION_CLASS, OBJECT_SLOT, POINT_CLASS, POINT_X_SLOT, POINT_Y_SLOT, PROJECT_VISIBILITY_CHECKER, RECTANGLE_CLASS, SECOND_OBJECT_SLOT_NAME, SECOND_OBJECT_SLOT_POINTER_NAME, UPPER_LEFT_CORNER_SLOT, WIRE_CONTROLPOINT_PRECISION, WIRE_MINIMUM_SIZE
 
Constructor Summary
DiagramUtilities()
           
 
Method Summary
static void addNewConnectorToNetwork(edu.stanford.smi.protege.model.Instance networkInstance, Actor actor)
           
static void addNewNodeToNetwork(edu.stanford.smi.protege.model.Instance networkInstance, Actor actor)
           
static void bindAlongConnection(edu.stanford.smi.protege.model.Instance connection)
           
static void cleanupLayoutInformation(edu.stanford.smi.protege.model.Instance underlyingNetworkInstance)
           
static Rectangle convertInstanceToRectangle(edu.stanford.smi.protege.model.Instance instanceOfRectangle)
           
static edu.stanford.smi.protege.model.Instance getFirstObject(edu.stanford.smi.protege.model.Instance connector)
           
static edu.stanford.smi.protege.model.Instance getInstanceRectangleForObject(edu.stanford.smi.protege.model.Instance object, edu.stanford.smi.protege.model.Instance networkInstance)
           
static Rectangle getLocationRectangleForObject(edu.stanford.smi.protege.model.Instance object, edu.stanford.smi.protege.model.Instance networkInstance)
           
static edu.stanford.smi.protege.model.Slot getNodeSlot(edu.stanford.smi.protege.model.Cls networkCls)
           
static edu.stanford.smi.protege.model.Instance getSecondObject(edu.stanford.smi.protege.model.Instance connector)
           
static void removeConnector(edu.stanford.smi.protege.model.Instance networkInstance, edu.stanford.smi.protege.model.Instance connector)
           
static void removeLayoutInformation(edu.stanford.smi.protege.model.Instance underlyingNetworkInstance, edu.stanford.smi.protege.model.Instance object)
           
static void removeNode(edu.stanford.smi.protege.model.Instance networkInstance, edu.stanford.smi.protege.model.Instance node)
           
static void setLocation(edu.stanford.smi.protege.model.KnowledgeBase kb, edu.stanford.smi.protege.model.Instance actorInstance, edu.stanford.smi.protege.model.Instance networkInstance, edu.stanford.smi.protege.model.Instance basePointInstance, edu.stanford.smi.protege.model.Instance endPointInstance)
           
static void unbindAlongConnection(edu.stanford.smi.protege.model.Instance connection)
           
static void updateConnectorLocation(edu.stanford.smi.protege.model.Instance networkInstance, Actor actor)
           
static void updateNodeLocation(edu.stanford.smi.protege.model.Instance networkInstance, Actor actor)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DiagramUtilities

public DiagramUtilities()
Method Detail

addNewConnectorToNetwork

public static void addNewConnectorToNetwork(edu.stanford.smi.protege.model.Instance networkInstance,
                                            Actor actor)

addNewNodeToNetwork

public static void addNewNodeToNetwork(edu.stanford.smi.protege.model.Instance networkInstance,
                                       Actor actor)

bindAlongConnection

public static void bindAlongConnection(edu.stanford.smi.protege.model.Instance connection)

cleanupLayoutInformation

public static void cleanupLayoutInformation(edu.stanford.smi.protege.model.Instance underlyingNetworkInstance)

convertInstanceToRectangle

public static Rectangle convertInstanceToRectangle(edu.stanford.smi.protege.model.Instance instanceOfRectangle)

getFirstObject

public static edu.stanford.smi.protege.model.Instance getFirstObject(edu.stanford.smi.protege.model.Instance connector)

getInstanceRectangleForObject

public static edu.stanford.smi.protege.model.Instance getInstanceRectangleForObject(edu.stanford.smi.protege.model.Instance object,
                                                                                    edu.stanford.smi.protege.model.Instance networkInstance)

getLocationRectangleForObject

public static Rectangle getLocationRectangleForObject(edu.stanford.smi.protege.model.Instance object,
                                                      edu.stanford.smi.protege.model.Instance networkInstance)

getNodeSlot

public static edu.stanford.smi.protege.model.Slot getNodeSlot(edu.stanford.smi.protege.model.Cls networkCls)

getSecondObject

public static edu.stanford.smi.protege.model.Instance getSecondObject(edu.stanford.smi.protege.model.Instance connector)

removeConnector

public static void removeConnector(edu.stanford.smi.protege.model.Instance networkInstance,
                                   edu.stanford.smi.protege.model.Instance connector)

removeLayoutInformation

public static void removeLayoutInformation(edu.stanford.smi.protege.model.Instance underlyingNetworkInstance,
                                           edu.stanford.smi.protege.model.Instance object)

removeNode

public static void removeNode(edu.stanford.smi.protege.model.Instance networkInstance,
                              edu.stanford.smi.protege.model.Instance node)

setLocation

public static void setLocation(edu.stanford.smi.protege.model.KnowledgeBase kb,
                               edu.stanford.smi.protege.model.Instance actorInstance,
                               edu.stanford.smi.protege.model.Instance networkInstance,
                               edu.stanford.smi.protege.model.Instance basePointInstance,
                               edu.stanford.smi.protege.model.Instance endPointInstance)

unbindAlongConnection

public static void unbindAlongConnection(edu.stanford.smi.protege.model.Instance connection)

updateConnectorLocation

public static void updateConnectorLocation(edu.stanford.smi.protege.model.Instance networkInstance,
                                           Actor actor)

updateNodeLocation

public static void updateNodeLocation(edu.stanford.smi.protege.model.Instance networkInstance,
                                      Actor actor)

Protege-2000 1.7

Submit a bug report or feature request
Protege-2000 is a trademark of Stanford University.
Copyright (c) 1998-2002 Stanford University.