Documentation
¶
Index ¶
- Variables
- func ValidateAuthStatusMedia(result *AuthStatusMedia) (err error)
- func ValidateAuthStatusMediaView(result *AuthStatusMediaView) (err error)
- func ValidateUserMedia(result *UserMedia) (err error)
- func ValidateUserMediaView(result *UserMediaView) (err error)
- type AuthStatusMedia
- type AuthStatusMediaView
- type UserMedia
- type UserMediaView
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // AuthStatusMediaMap is a map of attribute names in result type // AuthStatusMedia indexed by view name. AuthStatusMediaMap = map[string][]string{ "default": []string{ "google", "facebook", "twitter", "linkedin", "instagram", "standard", }, } // UserMediaMap is a map of attribute names in result type UserMedia indexed by // view name. UserMediaMap = map[string][]string{ "default": []string{ "id", "phone", "lastName", "updatedAt", "email", "createdAt", "firstName", "countryPhoneCode", "changingEmail", "isAdmin", "verifiedEmail", "Authorization", "X-Session", }, } )
Functions ¶
func ValidateAuthStatusMedia ¶
func ValidateAuthStatusMedia(result *AuthStatusMedia) (err error)
ValidateAuthStatusMedia runs the validations defined on the viewed result type AuthStatusMedia.
func ValidateAuthStatusMediaView ¶
func ValidateAuthStatusMediaView(result *AuthStatusMediaView) (err error)
ValidateAuthStatusMediaView runs the validations defined on AuthStatusMediaView using the "default" view.
func ValidateUserMedia ¶
ValidateUserMedia runs the validations defined on the viewed result type UserMedia.
func ValidateUserMediaView ¶
func ValidateUserMediaView(result *UserMediaView) (err error)
ValidateUserMediaView runs the validations defined on UserMediaView using the "default" view.
Types ¶
type AuthStatusMedia ¶
type AuthStatusMedia struct { // Type to project Projected *AuthStatusMediaView // View to render View string }
AuthStatusMedia is the viewed result type that is projected based on a view.
type AuthStatusMediaView ¶
type AuthStatusMediaView struct { // True if user has google Oauth signin Google *bool // True if user has facebook Oauth signin Facebook *bool // True if user has twitter Oauth signin Twitter *bool // True if user has linkedin Oauth signin Linkedin *bool // True if user has microsoft Oauth signin Instagram *bool // True if user has password signin Standard *bool }
AuthStatusMediaView is a type that runs validations on a projected type.
type UserMedia ¶
type UserMedia struct { // Type to project Projected *UserMediaView // View to render View string }
UserMedia is the viewed result type that is projected based on a view.
type UserMediaView ¶
type UserMediaView struct { // Unique unchanging user ID ID *string // Given name for the user FirstName *string // Family name for the user LastName *string // Email attached to the account of the user Email *string // Phone Number Of the user Phone *string // When the user attempts to change their email, this is what they will change // it to after they verify that it belongs to them ChangingEmail *string // Whether the user has verified their email VerifiedEmail *bool // Whether the user is an administrator on the site IsAdmin *bool UpdatedAt *string IsActive *bool CreatedAt *string CountryPhoneCode *string Authorization *string XSession *string }
UserMediaView is a type that runs validations on a projected type.
Click to show internal directories.
Click to hide internal directories.