NTPolygon
@interface NTPolygon : NTElement
این کلاس برای کار با چندضلعی geometry میباشد.
-
Constructs a Polygon object from a geometry object and a style.
Declaration
Objective-C
- (id)initWithGeometry:(NTPolygonGeom *)geometry style:(NTPolygonStyle *)style;
Swift
init!(geometry: NTPolygonGeom!, style: NTPolygonStyle!)
Parameters
geometry
The geometry object that defines the location and holes of this polygon.
style
The style that defines what this polygon looks like.
-
Constructs a Polygon object from a vector of map positions and a style.
Declaration
Objective-C
- (id)initWithPoses:(NTLngLatVector *)poses style:(NTPolygonStyle *)style;
Swift
init!(poses: NTLngLatVector!, style: NTPolygonStyle!)
Parameters
poses
The vector of map positions that defines the location of this polygon.
style
The style that defines what this polygon looks like.
-
با استفاده از برداری از نقاط روی نقشه، برداری از نقاط حفرهها و استایل مورد نظر یک شی از نوع Polygon میسازد.
Declaration
Objective-C
- (id)initWithPoses:(NTLngLatVector *)poses holes:(NTLngLatVectorVector *)holes style:(NTPolygonStyle *)style;
Swift
init!(poses: NTLngLatVector!, holes: NTLngLatVectorVector!, style: NTPolygonStyle!)
Parameters
poses
بردار موقعیتهای نقشه که موقعیت این چندضعلی را مشخص میکند
holes
بردار حفرهها که موقعیت حفرههای این چندضعلی را مشخص میکند
style
استایلی که به چندضعلی اعمال میشود
-
Undocumented
-
موقعیت این چندضلعی را تنظیم میکند.
Declaration
Objective-C
- (void)setGeometry:(NTPolygonGeom *)geometry;
Swift
func setGeometry(_ geometry: NTPolygonGeom!)
Parameters
geometry
شی geometry جدید که موقعیت و حفرههای آن را تنظیم میکند
-
گرههای این چندضلعی را بر می گرداند.
Return Value
بردار موقعیت این polygon
-
تنظیم گرههای تنظیم کننده این چندضلعی . با فراخوانی این متد حفرهها تحت تاثیر قرار نمی گیرند
Declaration
Objective-C
- (void)setPoses:(NTLngLatVector *)poses;
Swift
func setPoses(_ poses: NTLngLatVector!)
Parameters
poses
بردار جدید
-
Returns the holes of the polygon.
Declaration
Objective-C
- (NTLngLatVectorVector *)getHoles;
Swift
func getHoles() -> NTLngLatVectorVector!
Return Value
The list of holes of the polygon.
-
Sets the holes of the polygon.
Declaration
Objective-C
- (void)setHoles:(NTLngLatVectorVector *)holes;
Swift
func setHoles(_ holes: NTLngLatVectorVector!)
Parameters
holes
The list of holes of the polygon.
-
استایل این چند ضلعی را بر می گرداند.
Return Value
استایل چند ضلعی.
-
استایل این چند ضلعی را تنظیم میکند.
Declaration
Objective-C
- (void)setStyle:(NTPolygonStyle *)style;
Swift
func setStyle(_ style: NTPolygonStyle!)
Parameters
style
استایل جدید
-
Undocumented
Declaration
Objective-C
-(void)dealloc;