igeo
Class IServer

java.lang.Object
  extended by igeo.IServer
All Implemented Interfaces:
IServerI

public class IServer
extends java.lang.Object
implements IServerI

A class of server to contain and manage instances of IObject. Drawing function is separated to IGraphicServer.

Version:
0.7.0.0;
Author:
Satoru Sugihara
See Also:
IGraphicServer

Field Summary
 IDynamicServer dynamicServer
           
 IGraphicServer graphicServer
           
 IG ig
           
 java.util.ArrayList<ILayer> layers
           
 java.util.ArrayList<IObject> objects
           
 int stateCount
           
 
Constructor Summary
IServer(IG ig)
           
IServer(IG ig, IPanel panel)
           
 
Method Summary
 void add(IObject e)
           
 java.util.ArrayList<IObject> allObjects()
           
 void background(java.awt.Color c1, java.awt.Color c2, java.awt.Color c3, java.awt.Color c4)
           
 void bg(java.awt.Color c1, java.awt.Color c2, java.awt.Color c3, java.awt.Color c4)
           
 IBrep brep(int i)
          Returns i-th IBrep object contained in objects or null if not found.
 int brepNum()
          number of IBrep in objects
 IBrep[] breps()
          Returns all meshe objects contained in objects.
 void clear()
           
 ICurve curve(int i)
          Returns i-th ICurve object contained in objects or null if not found.
 int curveNum()
          number of ICurve in objects
 ICurve[] curves()
          Returns all curve objects contained in objects.
 void deleteLayer(int i)
           
 void deleteLayer(java.lang.String layerName)
           
 int duration()
           
 void duration(int dur)
           
 IDynamicServer dynamicServer()
           
 IGeometry[] geometries()
          Returns all geometry objects contained in objects.
 IGeometry geometry(int i)
          Returns i-th IGeometry object contained in objects or null if not found.
 int geometryNum()
          number of the IGeometry in objects
 ILayer[] getAllLayers()
           
 java.util.ArrayList<IObject> getAllObjects()
           
 IBrep getBrep(int i)
          alias of brep(int)
 int getBrepNum()
          alias of brepNum()
 IBrep[] getBreps()
          alias of breps
 ICurve getCurve(int i)
          alias of curve(int)
 int getCurveNum()
          alias of curveNum()
 ICurve[] getCurves()
          alias of curves()
 IGeometry[] getGeometries()
          alias of breps
 IGeometry getGeometry(int i)
          alias of geometry(int)
 int getGeometryNum()
          alias of geometryNum()
 ILayer getLayer(int i)
           
 ILayer getLayer(java.lang.String layerName)
           
 IMesh getMesh(int i)
          alias of mesh(int)
 IMesh[] getMeshes()
          alias of meshes()
 int getMeshNum()
          alias of meshNum()
 IObject getObject(java.lang.Class cls, int i)
          alias of object(Class,int)
 IObject getObject(int i)
           
 int getObjectNum()
          alias of objectNum()
 int getObjectNum(java.lang.Class cls)
          alias of objectNum(Class)
 IObject[] getObjects()
           
 IObject[] getObjects(java.lang.Class cls)
          alias of objects(Class)
 IPoint getPoint(int i)
          alias of point(int)
 int getPointNum()
          alias of pointsNum()
 IPoint[] getPoints()
          alias of points()
 ISurface getSurface(int i)
          alias of surface(int)
 int getSurfaceNum()
          alias of surfaceNum()
 ISurface[] getSurfaces()
          alias of surfaces()
 IGraphicServer graphicServer()
           
 boolean isGraphicMode()
           
 ILayer layer(int i)
           
 ILayer layer(java.lang.String layerName)
           
 int layerNum()
           
 ILayer[] layers()
           
 IMesh mesh(int i)
          Returns i-th IMesh object contained in objects or null if not found.
 IMesh[] meshes()
          Returns all meshe objects contained in objects.
 int meshNum()
          number of IMesh in objects
 IObject object(java.lang.Class cls, int i)
          Returns i-th object contained in objects or null if not found.
 IObject object(int i)
           
 int objectNum()
           
 int objectNum(java.lang.Class cls)
          number of the specified class in objects
 IObject[] objects()
          Returns all objects contained in objects.
 IObject[] objects(java.lang.Class cls)
          Returns all objects of specified class contained in objects.
 void pause()
           
 IPoint point(int i)
          Returns i-th IPoint object contained in objects or null if not found.
 int pointNum()
          number of IPoint in objects
 IPoint[] points()
          Returns all point objects contained in objects.
 void remove(int i)
           
 void remove(IObject e)
           
 void resume()
           
 IServer server()
           
 void setGraphicMode(IGraphicMode mode)
           
 void start()
           
 int stateCount()
           
 void stop()
           
 ISurface surface(int i)
          Returns i-th ISurface object contained in objects or null if not found.
 int surfaceNum()
          number of ISurface in objects
 ISurface[] surfaces()
          Returns all surface objects contained in objects.
 int time()
           
 void time(int tm)
           
 void updateState()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

objects

public java.util.ArrayList<IObject> objects

layers

public java.util.ArrayList<ILayer> layers

graphicServer

public IGraphicServer graphicServer

dynamicServer

public IDynamicServer dynamicServer

ig

public IG ig

stateCount

public int stateCount
Constructor Detail

IServer

public IServer(IG ig)

IServer

public IServer(IG ig,
               IPanel panel)
Method Detail

server

public IServer server()
Specified by:
server in interface IServerI

dynamicServer

public IDynamicServer dynamicServer()

graphicServer

public IGraphicServer graphicServer()

add

public void add(IObject e)

isGraphicMode

public boolean isGraphicMode()

setGraphicMode

public void setGraphicMode(IGraphicMode mode)

bg

public void bg(java.awt.Color c1,
               java.awt.Color c2,
               java.awt.Color c3,
               java.awt.Color c4)

background

public void background(java.awt.Color c1,
                       java.awt.Color c2,
                       java.awt.Color c3,
                       java.awt.Color c4)

getAllObjects

public java.util.ArrayList<IObject> getAllObjects()

allObjects

public java.util.ArrayList<IObject> allObjects()

getObject

public IObject getObject(int i)

object

public IObject object(int i)

objectNum

public int objectNum()

getObjectNum

public int getObjectNum()
alias of objectNum()


remove

public void remove(int i)

remove

public void remove(IObject e)

clear

public void clear()

stateCount

public int stateCount()

updateState

public void updateState()

duration

public void duration(int dur)

duration

public int duration()

time

public void time(int tm)

time

public int time()

pause

public void pause()

resume

public void resume()

start

public void start()

stop

public void stop()

points

public IPoint[] points()
Returns all point objects contained in objects. IPointR objects are not included.


getPoints

public IPoint[] getPoints()
alias of points()


curves

public ICurve[] curves()
Returns all curve objects contained in objects. ICurveR objects are not included.


getCurves

public ICurve[] getCurves()
alias of curves()


surfaces

public ISurface[] surfaces()
Returns all surface objects contained in objects. ISurfaceR objects are not included.


getSurfaces

public ISurface[] getSurfaces()
alias of surfaces()


meshes

public IMesh[] meshes()
Returns all meshe objects contained in objects. IMeshR objects are not included.


getMeshes

public IMesh[] getMeshes()
alias of meshes()


breps

public IBrep[] breps()
Returns all meshe objects contained in objects. IMeshR objects are not included.


getBreps

public IBrep[] getBreps()
alias of breps


geometries

public IGeometry[] geometries()
Returns all geometry objects contained in objects.


getGeometries

public IGeometry[] getGeometries()
alias of breps


objects

public IObject[] objects(java.lang.Class cls)
Returns all objects of specified class contained in objects.


getObjects

public IObject[] getObjects(java.lang.Class cls)
alias of objects(Class)


objects

public IObject[] objects()
Returns all objects contained in objects.


getObjects

public IObject[] getObjects()

point

public IPoint point(int i)
Returns i-th IPoint object contained in objects or null if not found. IPointR objects are not included.


getPoint

public IPoint getPoint(int i)
alias of point(int)


curve

public ICurve curve(int i)
Returns i-th ICurve object contained in objects or null if not found. ICurveR objects are not included.


getCurve

public ICurve getCurve(int i)
alias of curve(int)


surface

public ISurface surface(int i)
Returns i-th ISurface object contained in objects or null if not found. ISurfaceR objects are not included.


getSurface

public ISurface getSurface(int i)
alias of surface(int)


mesh

public IMesh mesh(int i)
Returns i-th IMesh object contained in objects or null if not found. IMeshR objects are not included.


getMesh

public IMesh getMesh(int i)
alias of mesh(int)


brep

public IBrep brep(int i)
Returns i-th IBrep object contained in objects or null if not found.


getBrep

public IBrep getBrep(int i)
alias of brep(int)


geometry

public IGeometry geometry(int i)
Returns i-th IGeometry object contained in objects or null if not found.


getGeometry

public IGeometry getGeometry(int i)
alias of geometry(int)


object

public IObject object(java.lang.Class cls,
                      int i)
Returns i-th object contained in objects or null if not found.


getObject

public IObject getObject(java.lang.Class cls,
                         int i)
alias of object(Class,int)


pointNum

public int pointNum()
number of IPoint in objects


getPointNum

public int getPointNum()
alias of pointsNum()


curveNum

public int curveNum()
number of ICurve in objects


getCurveNum

public int getCurveNum()
alias of curveNum()


surfaceNum

public int surfaceNum()
number of ISurface in objects


getSurfaceNum

public int getSurfaceNum()
alias of surfaceNum()


meshNum

public int meshNum()
number of IMesh in objects


getMeshNum

public int getMeshNum()
alias of meshNum()


brepNum

public int brepNum()
number of IBrep in objects


getBrepNum

public int getBrepNum()
alias of brepNum()


geometryNum

public int geometryNum()
number of the IGeometry in objects


getGeometryNum

public int getGeometryNum()
alias of geometryNum()


objectNum

public int objectNum(java.lang.Class cls)
number of the specified class in objects


getObjectNum

public int getObjectNum(java.lang.Class cls)
alias of objectNum(Class)


layerNum

public int layerNum()

layer

public ILayer layer(int i)

getLayer

public ILayer getLayer(int i)

layers

public ILayer[] layers()

getAllLayers

public ILayer[] getAllLayers()

getLayer

public ILayer getLayer(java.lang.String layerName)

layer

public ILayer layer(java.lang.String layerName)

deleteLayer

public void deleteLayer(java.lang.String layerName)

deleteLayer

public void deleteLayer(int i)