Avaya Client Services API Reference (iOS)
Instance Methods | Properties | List of all members
CSWhiteboardSurface Class Reference

The CSWhiteboardSurface object represents independent whiteboard surface containing all shapes drawn on given whiteboard surface. More...

#import <CSWhiteboardSurface.h>

Inherits NSObject.

Inherited by CSSlide.

Instance Methods

(void) - setAsActiveWithCompletionHandler:
 Selects this surface as the active whiteboard surface. More...
 
(CSShape *) - addShapeWithPoints:color:width:isFilled:isFinished:completionHandler:
 Adds a shape to the whiteboard surface. More...
 
(void) - finishShape:completionHandler:
 Marks shape as finished. More...
 
(CSCircleShape *) - addCircleWithTopLeft:bottomRight:color:width:isFilled:completionHandler:
 Adds a circle to the whiteboard surface. More...
 
(CSWhiteboardText *) - addText:atPosition:fontSize:color:completionHandler:
 Adds a text to the whiteboard surface. More...
 
(void) - updateShape:completionHandler:
 Updates given shape. More...
 
(void) - deleteShape:completionHandler:
 Deletes a shape from surface. More...
 
(void) - clearContentWithCompletionHandler:
 Removes all content from the drawing surface. More...
 

Properties

id< CSWhiteboardSurfaceDelegatedelegate
 The delegate used to handle events related to whiteboard surface. More...
 
NSString * surfaceId
 The whiteboard surface ID associated with the particular CSWhiteboardSurface object. More...
 
CSParticipantaddedBy
 Data of participant who added whiteboard surface. More...
 
CSParticipantremovedBy
 Data of participant who removed whiteboard surface. More...
 
NSArray * shapes
 Array containing all shapes belonging to this whiteboard surface as objects of class CSBasicShape. More...
 
CSCapabilitysetAsActiveCapability
 CSCapability object indicating whether the local user is allowed to set given whiteboard surface active. More...
 

Detailed Description

The CSWhiteboardSurface object represents independent whiteboard surface containing all shapes drawn on given whiteboard surface.

Whiteboard surface content is displayed on CSIOSWhiteboardCanvas. Client can obtain objects of this class using methods of class CSWhiteboard. Methods related to adding/modifying/removing particular shapes shouldn't be invoked by client explicitly unless custom whiteboard canvas is developed. Methods NSObject::isEqual and NSObject::hash are implemented for this class.

See also
CSWhiteboard

Method Documentation

- (CSCircleShape *) addCircleWithTopLeft: (CSShapePoint *)  topLeft
bottomRight: (CSShapePoint *)  bottomRight
color: (NSUInteger)  color
width: (NSUInteger)  width
isFilled: (BOOL)  filled
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Adds a circle to the whiteboard surface.

Method is deprecated. Use addCircleWithTopLeft:bottomRight:color:width:isFilled:completionHandler: instead.

Parameters
topLeftTop left point of circle
bottomRightBottom right point of circle.
colorColor of circle.
widthWidth of circle.
filledTrue if circle is filled.
handlerA block to be called when the operation is completed.
  • shape Added circle as CSBasicShape object.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
Returns
CSCircleShape object made with given parameters
- (CSShape *) addShapeWithPoints: (NSArray *)  points
color: (NSUInteger)  color
width: (NSUInteger)  width
isFilled: (BOOL)  filled
isFinished: (BOOL)  finished
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Adds a shape to the whiteboard surface.

Parameters
pointsArray of CSShapePoint points.
colorColor of shape.
widthWidth of shape.
filledTrue if shape is filled.
finishedSet to true when shape is finished / closed
handlerA block to be called when the operation is completed.
  • shape CSBasicShape object made with given points.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
Returns
CSShape object made with given points
- (CSWhiteboardText *) addText: (NSString *)  text
atPosition: (CSShapePoint *)  position
fontSize: (NSUInteger)  fontSize
color: (NSUInteger)  color
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Adds a text to the whiteboard surface.

Method is deprecated. Use addText:atPosition:fontSize:color:completionHandler: instead.

Parameters
textContent of the whiteboard text object.
positionPosition of the text on the whiteboard surface.
fontSizeFont size of the text.
colorColor of the text.
handlerA block to be called when the operation is completed.
  • shape Added text as CSBasicShape object.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
Returns
CSWhiteboardText object made with given parameters.
- (void) clearContentWithCompletionHandler: (void(^)(CSWhiteboardSurface *surface, NSError *error))  handler

Removes all content from the drawing surface.

It shouldn't be used by client unless custom whiteboard canvas is developed. See CSWhiteboardCanvas::clearWhiteboardWithCompletionHandler: and CSIOSWhiteboardCanvas::clearWhiteboardWithCompletionHandler.

Parameters
handlerA block to be called when the operation is completed.
  • surface Shape that was cleared if operation was successful.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
See also
CSWhiteboardCanvas::clearWhiteboardWithCompletionHandler:
- clearWhiteboardWithCompletionHandler: (CSIOSWhiteboardCanvas)
- (void) deleteShape: (CSBasicShape *)  shape
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Deletes a shape from surface.

Parameters
shapeCSBasicShape object to be deleted from whiteboard surface.
handlerA block to be called when the operation is completed.
  • shape Deleted shape.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
- (void) finishShape: (CSBasicShape *)  shape
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Marks shape as finished.

Parameters
shapeCSBasicShape to be marked as finished.
handlerA block to be called when the operation is completed.
  • shape CSBasicShape object marked as finished.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
See also
- finishShape:completionHandler:
- (void) setAsActiveWithCompletionHandler: (void(^)(CSWhiteboardSurface *surface, CSParticipant *participant, NSError *error))  handler

Selects this surface as the active whiteboard surface.

Only one surface can be active during a collaboration session.

Parameters
handlerA block to be called when the operation is completed.
  • surface CSWhiteboardSurface object set as active.
  • participant CSParticipant object providing information about collaboration participant who set surface as active (local user in case of this method).
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.
- (void) updateShape: (CSBasicShape *)  shape
completionHandler: (void(^)(CSBasicShape *shape, NSError *error))  handler 

Updates given shape.

Can be used to continue drawing or to move given shape.

Parameters
shapeCSBasicShape to be updated or moved.
handlerA block to be called when the operation is completed.
  • shape Updated/moved shape.
  • error If the operation was successful this parameter is nil. If an error occurred it contains an object describing the error.

Property Documentation

- (CSParticipant*) addedBy
readnonatomicassign

Data of participant who added whiteboard surface.

- (id<CSWhiteboardSurfaceDelegate>) delegate
readwritenonatomicweak

The delegate used to handle events related to whiteboard surface.

- (CSParticipant*) removedBy
readnonatomicassign

Data of participant who removed whiteboard surface.

- (CSCapability*) setAsActiveCapability
readnonatomiccopy

CSCapability object indicating whether the local user is allowed to set given whiteboard surface active.

To do so, the local user needs to be moderator, presenter or panel model mode has to be enabled.

See also
- setAsActiveWithCompletionHandler:
- (NSArray*) shapes
readnonatomicassign

Array containing all shapes belonging to this whiteboard surface as objects of class CSBasicShape.

See also
CSBasicShape
- (NSString*) surfaceId
readnonatomicassign

The whiteboard surface ID associated with the particular CSWhiteboardSurface object.


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