ManagedAuthToken class Null safety

Represent an OAuth 2.0 authorization token and authorization code.

Instances of this type are created by ManagedAuthDelegate to store authorization tokens and codes on behalf of an AuthServer. There is no need to use this class directly.

Inheritance

Constructors

ManagedAuthToken()
Empty instance.
ManagedAuthToken.fromCode(AuthCode code)
Instance from an AuthCode.
ManagedAuthToken.fromToken(AuthToken t)
Instance from an AuthToken.

Properties

accessToken String?
The access token of an authorization token.
@Column(indexed: true, unique: true, nullable: true)read / writeinherited
backing ManagedBacking
The persistent values of this object.
read / writeinherited
client ManagedAuthClient?
The client this token was issued for.
@Relate(Symbol('tokens'), onDelete: DeleteRule.cascade, isRequired: true)read / writeinherited
code String?
The authorization code of this token.
@Column(indexed: true, unique: true, nullable: true)read / writeinherited
entity ManagedEntity
The ManagedEntity this instance is described by.
read / writeinherited
expirationDate DateTime?
When this token will expire.
@Column(indexed: true)read / writeinherited
hashCode int
The hash code for this object.
read-onlyinherited
id int?
A primary key identifier.
@primaryKeyread / writeinherited
issueDate DateTime?
When this token was last issued or refreshed.
read / writeinherited
refreshToken String?
The refresh token of an authorization token.
@Column(indexed: true, unique: true, nullable: true)read / writeinherited
resourceOwner ResourceOwnerTableDefinition?
The resource owner of this token.
@Relate(DeleteRule.cascade, isRequired: true)read / writeinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
scope String?
Scopes for this token, delimited by the space character.
@Column(nullable: true)read / writeinherited
type String?
The value 'bearer'.
@Column(indexed: true, nullable: true)read / writeinherited

Methods

asAuthCode() AuthCode
As an AuthCode.
asMap() Map<String, dynamic>
Converts this instance into a serializable map.
inherited
asToken() AuthToken
As an AuthToken.
documentSchema(APIDocumentContext context) APISchemaObject
Returns an APISchemaObject describing this object's type.
inherited
hasValueForProperty(String propertyName) bool
Checks whether or not a property has been set in this instances' backing.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
read(Map<String, dynamic> object, {Iterable<String>? accept, Iterable<String>? ignore, Iterable<String>? reject, Iterable<String>? require}) → void
Reads values from object, after applying filters.
inherited
readFromMap(Map<String, dynamic> object) → void
Reads values from object.
inherited
removePropertiesFromBackingMap(List<String> propertyNames) → void
Removes multiple properties from backing.
inherited
removePropertyFromBackingMap(String propertyName) → void
Removes a property from backing.
inherited
toString() String
A string representation of this object.
inherited
validate({Validating forEvent = Validating.insert}) ValidationContext
Validates an object according to its property Validate metadata.
@mustCallSuperinherited
willInsert() → void
Callback to modify an object prior to inserting it with a Query.
inherited
willUpdate() → void
Callback to modify an object prior to updating it with a Query.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited
operator [](String propertyName) → dynamic
Retrieves a value by property name from backing.
inherited
operator []=(String propertyName, dynamic value) → void
Sets a value by property name in backing.
inherited