SFSegment

Objective-C

@interface SFSegment : NSObject

Swift

class SFSegment : NSObject

Line segment of an edge between two points

  • Segment above

    Declaration

    Objective-C

    @property (nonatomic, strong) SFSegment *above;

    Swift

    var above: SFSegment! { get set }
  • Segment below

    Declaration

    Objective-C

    @property (nonatomic, strong) SFSegment *below;

    Swift

    var below: SFSegment! { get set }
  • Initialize

    Declaration

    Objective-C

    - (instancetype)initWithEdge:(int)edge
                         andRing:(int)ring
                    andLeftPoint:(SFPoint *)leftPoint
                   andRightPoint:(SFPoint *)rightPoint;

    Swift

    init!(edge: Int32, andRing ring: Int32, andLeftPoint leftPoint: SFPoint!, andRightPoint rightPoint: SFPoint!)

    Parameters

    edge

    edge number

    ring

    ring number

    leftPoint

    left point

    rightPoint

    right point

    Return Value

    segment

  • Get the edge number

    Declaration

    Objective-C

    - (int)edge;

    Swift

    func edge() -> Int32

    Return Value

    edge number

  • Get the polygon ring number

    Declaration

    Objective-C

    - (int)ring;

    Swift

    func ring() -> Int32

    Return Value

    polygon ring number

  • Get the left point

    Declaration

    Objective-C

    - (SFPoint *)leftPoint;

    Swift

    func leftPoint() -> SFPoint!

    Return Value

    left point

  • Get the right point

    Declaration

    Objective-C

    - (SFPoint *)rightPoint;

    Swift

    func rightPoint() -> SFPoint!

    Return Value

    right point