+
+
+

Classes

+

The following classes are available globally.

+ +
+
+
+
    +
  • +
    + + + + UsergridResponseError + +
    +
    +
    +
    +
    +
    +

    A standard error object that contains details about a request failure.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridResponseError: NSObject
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridRequest + +
    +
    +
    +
    +
    +
    +

    The UsergridRequest class incapsulates the properties that all requests made by the SDK have in common.

    + +

    This class is also functions to create NSURLRequest objects based on the properties of the class.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridRequest : NSObject
    + +
    +
    +
    +
    +
  • +
  • + +
    +
    +
    +
    +
    +

    The UsergridRequest sub class which is used for uploading assets.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridAssetUploadRequest: UsergridRequest
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridClientConfig + +
    +
    +
    +
    +
    +
    +

    UsergridClientConfig is used when initializing UsergridClient objects.

    + +

    The UsergridClientConfig is meant for further customization of UsergridClient objects when needed.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridClientConfig : NSObject, NSCoding
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridAuth + +
    +
    +
    +
    +
    +
    +

    The UsergridAuth class functions to create and store authentication information used by Usergrid.

    + +

    The UsergridAuth sub classes, UsergridAppAuth and UsergridUserAuth, provide different ways for authentication to be used in creating requests for access tokens through the SDK.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridAuth : NSObject, NSCoding
    + +
    +
    +
    +
    +
  • +
  • +
    + + + + UsergridUserAuth + +
    +
    +
    +
    +
    +
    +

    The UsergridAuth subclass used for user level authorization.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridUserAuth : UsergridAuth
    + +
    +
    +
    +
    +
  • +
  • +
    + + + + UsergridAppAuth + +
    +
    +
    +
    +
    +
    +

    The UsergridAuth subclass used for application level authorization.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridAppAuth : UsergridAuth
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridFileMetaData + +
    +
    +
    +
    +
    +
    +

    UsergridFileMetaData is a helper class for dealing with reading UsergridEntity file meta data.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridFileMetaData : NSObject,NSCoding
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridDevice + +
    +
    +
    +
    +
    +
    +

    UsergridDevice is an UsergridEntity subclass that encapsulates information about the current device as well as stores information about push tokens and Usergrid notifiers.

    + +

    To apply push tokens for Usergrid notifiers use the UsergridClient.applyPushToken method.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridDevice : UsergridEntity
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridQuery + +
    +
    +
    +
    +
    +
    +

    UsergridQuery is builder class used to construct filtered requests to Usergrid.

    + +

    UsergridQuery objects are then passed to UsergridClient or Usergrid methods which support UsergridQuery as a parameter are .GET(), .PUT(), and .DELETE().

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridQuery : NSObject,NSCopying
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridEntity + +
    +
    +
    +
    +
    +
    +

    UsergridEntity is the base class that contains a single Usergrid entity.

    + +

    UsergridEntity maintains a set of accessor properties for standard Usergrid schema properties (e.g. name, uuid), and supports helper methods for accessing any custom properties that might exist.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridEntity: NSObject, NSCoding
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridUser + +
    +
    +
    +
    +
    +
    +

    UsergridUser is a special subclass of UsergridEntity that supports functions and properties unique to users.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridUser : UsergridEntity
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + Usergrid + +
    +
    +
    +
    +
    +
    +

    The Usergrid class acts as a static shared instance manager for the UsergridClient class.

    + +

    The methods and variables in this class are all static and therefore you will never need or want to initialize an instance of the Usergrid class.

    + +

    Use of this class depends on initialization of the shared instance of the UsergridClient object. Because of this, before using any of the static methods +provided you will need to call one of the shared instance initialization methods. Failure to do so will result in failure from all methods.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class Usergrid: NSObject
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridResponse + +
    +
    +
    +
    +
    +
    +

    UsergridResponse is the core class that handles both successful and unsuccessful HTTP responses from Usergrid.

    + +

    If a request is successful, any entities returned in the response will be automatically parsed into UsergridEntity objects and pushed to the entities property.

    + +

    If a request fails, the UsergridResponseError.error property will contain information about the problem encountered.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridResponse: NSObject
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridAsset + +
    +
    +
    +
    +
    +
    +

    As Usergrid supports storing binary assets, the SDKs are designed to make uploading assets easier and more robust. Attaching, uploading, and downloading assets is handled by the UsergridEntity class.

    + +

    Unless defined, whenever possible, the content-type will be inferred from the data provided, and the attached file (if not already a byte-array representation) will be binary-encoded.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridAsset: NSObject, NSCoding
    + +
    +
    +
    +
    +
  • +
+
+
+
    +
  • +
    + + + + UsergridClient + +
    +
    +
    +
    +
    +
    +

    The UsergridClient class is the base handler for making client connections to and managing relationships with Usergrid’s API.

    + + See more +
    +
    +

    Declaration

    +
    +

    Swift

    +
    public class UsergridClient: NSObject, NSCoding
    + +
    +
    +
    +
    +
  • +
+
+
+
+ +