Inheritance: System.Data.Objects.DataClasses.EntityObject
Ejemplo n.º 1
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Tokens EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToTokens(Token token)
 {
     base.AddObject("Tokens", token);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Create a new Token object.
 /// </summary>
 /// <param name="key">Initial value of the Key property.</param>
 /// <param name="userName">Initial value of the UserName property.</param>
 /// <param name="expirationDate">Initial value of the ExpirationDate property.</param>
 /// <param name="createdDate">Initial value of the CreatedDate property.</param>
 public static Token CreateToken(global::System.String key, global::System.String userName, global::System.DateTime expirationDate, global::System.DateTime createdDate)
 {
     Token token = new Token();
     token.Key = key;
     token.UserName = userName;
     token.ExpirationDate = expirationDate;
     token.CreatedDate = createdDate;
     return token;
 }
Ejemplo n.º 3
0
 public void DeleteToken(Token token)
 {
     this.DataContext.Tokens.DeleteObject(token);
     this.DataContext.SaveChanges();
 }
Ejemplo n.º 4
0
 public void UpdateToken(Token token)
 {
     this.DataContext.SaveChanges();
 }
Ejemplo n.º 5
0
 public void AddToken(Token token)
 {
     this.DataContext.Tokens.AddObject(token);
     this.DataContext.SaveChanges();
 }