Back to index

moin  1.9.0~rc2
Public Member Functions | Private Attributes | Static Private Attributes
CH.ifa.draw.standard.OffsetLocator Class Reference

A locator to offset another Locator. More...

Inheritance diagram for CH.ifa.draw.standard.OffsetLocator:
Inheritance graph
[legend]
Collaboration diagram for CH.ifa.draw.standard.OffsetLocator:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 OffsetLocator ()
 OffsetLocator (Locator base)
 OffsetLocator (Locator base, int offsetX, int offsetY)
Point locate (Figure owner)
void moveBy (int dx, int dy)
void write (StorableOutput dw)
 Stores the arrow tip to a StorableOutput.
void read (StorableInput dr) throws IOException
 Reads the arrow tip from a StorableInput.
Object clone ()
String getMap ()

Private Attributes

int offsetLocatorSerializedDataVersion = 1
Locator fBase
int fOffsetX
int fOffsetY

Static Private Attributes

static final long serialVersionUID = 2679950024611847621L

Detailed Description

A locator to offset another Locator.

See also:
Locator

Definition at line 17 of file OffsetLocator.java.


Constructor & Destructor Documentation

Definition at line 29 of file OffsetLocator.java.

                           {
        fBase = null;
        fOffsetX = 0;
        fOffsetY = 0;
    }

Definition at line 35 of file OffsetLocator.java.

                                       {
        this();
        fBase = base;
    }
CH.ifa.draw.standard.OffsetLocator.OffsetLocator ( Locator  base,
int  offsetX,
int  offsetY 
) [inline]

Definition at line 40 of file OffsetLocator.java.

                                                                 {
        this(base);
        fOffsetX = offsetX;
        fOffsetY = offsetY;
    }

Member Function Documentation

Object CH.ifa.draw.standard.AbstractLocator.clone ( ) [inline, inherited]

Definition at line 29 of file AbstractLocator.java.

                          {
        try {
            return super.clone();
        } catch (CloneNotSupportedException e) {
               throw new InternalError();
        }
    }
String CH.ifa.draw.standard.AbstractLocator.getMap ( ) [inline, inherited]

Definition at line 43 of file AbstractLocator.java.

                           {
       return "";
    }
Point CH.ifa.draw.standard.OffsetLocator.locate ( Figure  owner) [inline]

Definition at line 46 of file OffsetLocator.java.

                                      {
        Point p = fBase.locate(owner);
        p.x += fOffsetX;
        p.y += fOffsetY;
        return p;
    }
void CH.ifa.draw.standard.OffsetLocator.moveBy ( int  dx,
int  dy 
) [inline]

Definition at line 53 of file OffsetLocator.java.

                                       {
        fOffsetX += dx;
        fOffsetY += dy;
    }
void CH.ifa.draw.standard.OffsetLocator.read ( StorableInput  dr) throws IOException [inline]

Reads the arrow tip from a StorableInput.

Reimplemented from CH.ifa.draw.standard.AbstractLocator.

Definition at line 65 of file OffsetLocator.java.

                                                          {
        super.read(dr);
        fOffsetX = dr.readInt();
        fOffsetY = dr.readInt();
        fBase = (Locator)dr.readStorable();
    }

Here is the caller graph for this function:

void CH.ifa.draw.standard.OffsetLocator.write ( StorableOutput  dw) [inline]

Stores the arrow tip to a StorableOutput.

Reimplemented from CH.ifa.draw.standard.AbstractLocator.

Definition at line 58 of file OffsetLocator.java.

                                         {
        super.write(dw);
        dw.writeInt(fOffsetX);
        dw.writeInt(fOffsetY);
        dw.writeStorable(fBase);
    }

Here is the caller graph for this function:


Member Data Documentation

Definition at line 25 of file OffsetLocator.java.

Definition at line 26 of file OffsetLocator.java.

Definition at line 27 of file OffsetLocator.java.

Definition at line 23 of file OffsetLocator.java.

final long CH.ifa.draw.standard.OffsetLocator.serialVersionUID = 2679950024611847621L [static, private]

Definition at line 22 of file OffsetLocator.java.


The documentation for this class was generated from the following file: