Sofia API Reference

  • Package Index
  • Class Index
  • Packages
  • sofia.app
  • sofia.content
  • sofia.data
  • sofia.graphics
    • Interfaces
    • Joint
    • PropertyTransformer
    • Classes
    • AbstractJoint
    • Anchor
    • Color
    • CoordinateSystem
    • DirectionalPad
    • DistanceJoint
    • ElasticInInterpolator
    • ElasticInOutInterpolator
    • ElasticOutInterpolator
    • FillableShape
    • FillableShape.Animator
    • Geometry
    • Image
    • LineShape
    • MotionStep
    • OvalShape
    • PointAndAnchor
    • Polygon
    • PolygonShape
    • Predicate
    • RectangleShape
    • RevoluteJoint
    • Shape
    • Shape.Animator
    • Shape.Filter
    • ShapeField
    • ShapeFilter
    • ShapeSet
    • ShapeView
    • SizeF
    • StrokedShape
    • StrokedShape.Animator
    • TextShape
    • TextShape.Animator
    • Timings
    • ViewEdges
    • ZIndexComparator
    • Enums
    • RepeatMode
    • ShapeMotion
  • sofia.util
  • sofia.view
  • sofia.widget

public class
ViewEdges

extends Object

Inheritance

  • java.lang.Object
    • sofia.graphics.ViewEdges

Class Overview

Represents one or more of the four edges of a view, used with collision detection.


Summary

Public Constructors
ViewEdges(boolean left, boolean top, boolean right, boolean bottom)
Creates a new ViewEdges object that includes the specified edges.
Public Methods
boolean any()
Gets a value indicating whether the receiver includes any edge.
boolean bottom()
Gets a value indicating whether the receiver includes the bottom edge.
ViewEdges clone()
Creates a copy of the receiver that represents the same edges as the original.
boolean equals(Object other)
Compares two ViewEdges objects and returns a value indicating whether or not they represent exactly the same edges.
int hashCode()
boolean horizontal()
Gets a value indicating whether the receiver includes any horizontal edge; that is, the top or the bottom edge.
boolean left()
Gets a value indicating whether the receiver includes the left edge.
boolean right()
Gets a value indicating whether the receiver includes the right edge.
String toString()
boolean top()
Gets a value indicating whether the receiver includes the top edge.
boolean vertical()
Gets a value indicating whether the receiver includes any vertical edge; that is, the left or the right edge.
Methods inherited from class java.lang.Object
Object clone()
boolean equals(Object arg0)
void finalize()
final Class<?> getClass()
int hashCode()
final void notify()
final void notifyAll()
String toString()
final void wait()
final void wait(long arg0, int arg1)
final void wait(long arg0)

Public Constructors

public ViewEdges (boolean left, boolean top, boolean right, boolean bottom)

Creates a new ViewEdges object that includes the specified edges.

Parameters
left
true to include the left edge
top
true to include the top edge
right
true to include the right edge
bottom
true to include the bottom edge

Public Methods

public boolean any ()

Gets a value indicating whether the receiver includes any edge.

Returns

true if the receiver includes any edge, otherwise false

public boolean bottom ()

Gets a value indicating whether the receiver includes the bottom edge.

Returns

true if the receiver includes the bottom edge, otherwise false

public ViewEdges clone ()

Creates a copy of the receiver that represents the same edges as the original.

Returns

a copy of the receiver

public boolean equals (Object other)

Compares two ViewEdges objects and returns a value indicating whether or not they represent exactly the same edges.

Parameters
other
the other object to compare
Returns

true if the other object represents the same edges, otherwise false

public int hashCode ()

public boolean horizontal ()

Gets a value indicating whether the receiver includes any horizontal edge; that is, the top or the bottom edge.

Returns

true if the receiver includes the top or bottom edge, otherwise false

public boolean left ()

Gets a value indicating whether the receiver includes the left edge.

Returns

true if the receiver includes the left edge, otherwise false

public boolean right ()

Gets a value indicating whether the receiver includes the right edge.

Returns

true if the receiver includes the right edge, otherwise false

public String toString ()

public boolean top ()

Gets a value indicating whether the receiver includes the top edge.

Returns

true if the receiver includes the top edge, otherwise false

public boolean vertical ()

Gets a value indicating whether the receiver includes any vertical edge; that is, the left or the right edge.

Returns

true if the receiver includes the left or right edge, otherwise false