diff options
Diffstat (limited to 'samples')
4 files changed, 33 insertions, 1 deletions
diff --git a/samples/OAuthAuthorizationServer/Code/Client.cs b/samples/OAuthAuthorizationServer/Code/Client.cs index ce52008..d33dc3f 100644 --- a/samples/OAuthAuthorizationServer/Code/Client.cs +++ b/samples/OAuthAuthorizationServer/Code/Client.cs @@ -29,6 +29,13 @@ } /// <summary> + /// Gets the type of the client. + /// </summary> + ClientType IClientDescription.ClientType { + get { return (ClientType)this.ClientType; } + } + + /// <summary> /// Determines whether a callback URI included in a client's authorization request /// is among those allowed callbacks for the registered client. /// </summary> diff --git a/samples/OAuthAuthorizationServer/Code/DataClasses.dbml b/samples/OAuthAuthorizationServer/Code/DataClasses.dbml index 5536b6e..fe621c2 100644 --- a/samples/OAuthAuthorizationServer/Code/DataClasses.dbml +++ b/samples/OAuthAuthorizationServer/Code/DataClasses.dbml @@ -15,6 +15,7 @@ <Column Name="ClientSecret" Type="System.String" DbType="NVarChar(50)" CanBeNull="true" /> <Column Name="Callback" Type="System.String" CanBeNull="true" /> <Column Name="Name" Type="System.String" CanBeNull="false" /> + <Column Member="ClientType" Type="System.Int32" CanBeNull="false" /> <Association Name="Client_ClientAuthorization" Member="ClientAuthorizations" Storage="_OAuthTokens" ThisKey="ClientId" OtherKey="ClientId" Type="ClientAuthorization" /> </Type> </Table> diff --git a/samples/OAuthAuthorizationServer/Code/DataClasses.designer.cs b/samples/OAuthAuthorizationServer/Code/DataClasses.designer.cs index 5035753..a1e4b83 100644 --- a/samples/OAuthAuthorizationServer/Code/DataClasses.designer.cs +++ b/samples/OAuthAuthorizationServer/Code/DataClasses.designer.cs @@ -272,6 +272,8 @@ namespace OAuthAuthorizationServer.Code private string _Name; + private int _ClientType; + private EntitySet<ClientAuthorization> _OAuthTokens; #region Extensibility Method Definitions @@ -288,6 +290,8 @@ namespace OAuthAuthorizationServer.Code partial void OnCallbackChanged(); partial void OnNameChanging(string value); partial void OnNameChanged(); + partial void OnClientTypeChanging(int value); + partial void OnClientTypeChanged(); #endregion public Client() @@ -396,6 +400,26 @@ namespace OAuthAuthorizationServer.Code } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ClientType")] + public int ClientType + { + get + { + return this._ClientType; + } + set + { + if ((this._ClientType != value)) + { + this.OnClientTypeChanging(value); + this.SendPropertyChanging(); + this._ClientType = value; + this.SendPropertyChanged("ClientType"); + this.OnClientTypeChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Client_ClientAuthorization", Storage="_OAuthTokens", ThisKey="ClientId", OtherKey="ClientId")] public EntitySet<ClientAuthorization> ClientAuthorizations { diff --git a/samples/OAuthConsumerWpf/Authorize2.xaml.cs b/samples/OAuthConsumerWpf/Authorize2.xaml.cs index 2201d3e..5785a6e 100644 --- a/samples/OAuthConsumerWpf/Authorize2.xaml.cs +++ b/samples/OAuthConsumerWpf/Authorize2.xaml.cs @@ -31,7 +31,7 @@ get { return this.clientAuthorizationView.Authorization; } } - private void clientAuthorizationView_Completed(object sender, ClientAuthorizationView.ClientAuthorizationCompleteEventArgs e) { + private void clientAuthorizationView_Completed(object sender, ClientAuthorizationCompleteEventArgs e) { this.DialogResult = e.Authorization != null; this.Close(); } |