Class OAuthTokenService
Inheritance
System.Object
OAuthTokenService
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Simplic.Framework.Mailing
Assembly: Simplic.Framework.dll
Syntax
public class OAuthTokenService : IOAuthTokenService, IOAuthTokenRepository
Constructors
| Improve this Doc View SourceOAuthTokenService(IOAuthTokenRepository)
Creates a new OAuth token service
Declaration
public OAuthTokenService(IOAuthTokenRepository repository)
Parameters
Type | Name | Description |
---|---|---|
IOAuthTokenRepository | repository |
Methods
| Improve this Doc View SourceDelete(OAuthToken)
Declaration
public bool Delete(OAuthToken obj)
Parameters
Type | Name | Description |
---|---|---|
OAuthToken | obj |
Returns
Type | Description |
---|---|
System.Boolean |
Delete(Guid)
Declaration
public bool Delete(Guid id)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | id |
Returns
Type | Description |
---|---|
System.Boolean |
Get(Guid)
Declaration
public OAuthToken Get(Guid id)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | id |
Returns
Type | Description |
---|---|
OAuthToken |
GetAll()
Declaration
public IEnumerable<OAuthToken> GetAll()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<OAuthToken> |
GetByUserAndTenantId(Int32, Guid)
Gets the token by the user ID and tenant ID
Declaration
public OAuthToken GetByUserAndTenantId(int userId, Guid tenantId)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | userId | |
System.Guid | tenantId |
Returns
Type | Description |
---|---|
OAuthToken | the token |
GetIdByUserAndTenantId(Int32, Guid)
Gets the id of the token by the user ID and tenant ID
Declaration
public Guid GetIdByUserAndTenantId(int userId, Guid tenantId)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | userId | |
System.Guid | tenantId |
Returns
Type | Description |
---|---|
System.Guid | the token |
Save(OAuthToken)
Declaration
public bool Save(OAuthToken obj)
Parameters
Type | Name | Description |
---|---|---|
OAuthToken | obj |
Returns
Type | Description |
---|---|
System.Boolean |
Implements
IRepositoryBase<, >