Free cookie consent management tool by TermsFeed Policy Generator

Changeset 7534


Ignore:
Timestamp:
02/28/12 15:46:53 (13 years ago)
Author:
ascheibe
Message:

#1648 worked on user and client information singletons

Location:
branches/ClientUserManagement
Files:
10 added
10 edited

Legend:

Unmodified
Added
Removed
  • branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/HeuristicLab.Clients.Access-3.3.csproj

    r7436 r7534  
    3838  </PropertyGroup>
    3939  <ItemGroup>
     40    <Reference Include="HeuristicLab.Algorithms.Benchmarks-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL" />
    4041    <Reference Include="HeuristicLab.Clients.Common-3.3">
    4142      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Clients.Common-3.3.dll</HintPath>
     
    7475      <Private>False</Private>
    7576    </Reference>
     77    <Reference Include="HeuristicLab.Optimization-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL" />
     78    <Reference Include="HeuristicLab.Optimizer-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL" />
    7679    <Reference Include="HeuristicLab.Persistence-3.3">
    7780      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Persistence-3.3.dll</HintPath>
     
    8588    <Reference Include="System.Core" />
    8689    <Reference Include="System.Drawing" />
     90    <Reference Include="System.Management" />
    8791    <Reference Include="System.Runtime.Serialization" />
    8892    <Reference Include="System.ServiceModel" />
     
    96100  <ItemGroup>
    97101    <Compile Include="AccessClient.cs" />
     102    <Compile Include="ClientInformation.cs" />
     103    <Compile Include="ClientInformationUtils.cs" />
     104    <Compile Include="ClientViews\ClientView.cs">
     105      <SubType>UserControl</SubType>
     106    </Compile>
     107    <Compile Include="ClientViews\ClientView.Designer.cs">
     108      <DependentUpon>ClientView.cs</DependentUpon>
     109    </Compile>
     110    <Compile Include="MenuItems\ClientInfoMenuItem.cs" />
    98111    <Compile Include="Plugin.cs" />
    99112    <Compile Include="Properties\AssemblyInfo.cs" />
    100113    <Compile Include="ServiceClients\AccessServiceClient.cs" />
    101114    <Compile Include="ServiceClients\AccessItem.cs" />
     115    <Compile Include="ServiceClients\ClientGroup.cs" />
     116    <Compile Include="ServiceClients\Client.cs" />
     117    <Compile Include="ServiceClients\Resource.cs" />
    102118    <Compile Include="ServiceClients\IAccessItem.cs" />
    103119    <Compile Include="ServiceClients\LightweightUser.cs" />
     
    146162    <None Include="UpdateLocalInstallation.cmd" />
    147163  </ItemGroup>
     164  <ItemGroup />
    148165  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
    149166  <PropertyGroup>
  • branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/Plugin.cs.frame

    r7368 r7534  
    2929  [PluginFile("HeuristicLab.Clients.Access-3.3.dll", PluginFileType.Assembly)] 
    3030  [PluginDependency("HeuristicLab.Clients.Common", "3.3")]
     31  [PluginDependency("HeuristicLab.Algorithms.Benchmarks", "3.3")]
     32  [PluginDependency("HeuristicLab.Optimization", "3.3")]
    3133  [PluginDependency("HeuristicLab.Collections", "3.3")]
     34  [PluginDependency("HeuristicLab.Optimizer", "3.3")]
    3235  [PluginDependency("HeuristicLab.Common", "3.3")]
    3336  [PluginDependency("HeuristicLab.Common.Resources", "3.3")]
  • branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/ServiceClients/AccessServiceClient.cs

    r7436 r7534  
    22// <auto-generated>
    33//     This code was generated by a tool.
    4 //     Runtime Version:4.0.30319.239
     4//     Runtime Version:4.0.30319.261
    55//
    66//     Changes to this file may cause incorrect behavior and will be lost if
     
    1818  [System.SerializableAttribute()]
    1919  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.User))]
     20  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.UserGroup))]
    2021  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.LightweightUser))]
    21   [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.UserGroup))]
    2222  public partial class UserGroupBase : HeuristicLab.Clients.Access.AccessItem {
    2323
     
    5656  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.UserGroupBase))]
    5757  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.User))]
     58  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.UserGroup))]
    5859  [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.LightweightUser))]
    59   [System.Runtime.Serialization.KnownTypeAttribute(typeof(HeuristicLab.Clients.Access.UserGroup))]
    6060  public partial class AccessItem : object, System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged {
    6161
     
    7373
    7474    public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
     75
     76
    7577  }
    7678
     
    306308
    307309    [System.Runtime.Serialization.OptionalFieldAttribute()]
     310    private double PerformanceValueField;
     311
     312    [System.Runtime.Serialization.OptionalFieldAttribute()]
    308313    private string ProcessorTypeField;
    309314
     
    403408
    404409    [System.Runtime.Serialization.DataMemberAttribute()]
     410    public double PerformanceValue {
     411      get {
     412        return this.PerformanceValueField;
     413      }
     414      set {
     415        if ((this.PerformanceValueField.Equals(value) != true)) {
     416          this.PerformanceValueField = value;
     417          this.RaisePropertyChanged("PerformanceValue");
     418        }
     419      }
     420    }
     421
     422    [System.Runtime.Serialization.DataMemberAttribute()]
    405423    public string ProcessorType {
    406424      get {
     
    823841  [System.Diagnostics.DebuggerStepThroughAttribute()]
    824842  [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
     843  [System.Runtime.Serialization.DataContractAttribute(Name = "UserGroup", Namespace = "http://schemas.datacontract.org/2004/07/HeuristicLab.Services.Access.DataTransfer" +
     844      "")]
     845  [System.SerializableAttribute()]
     846  public partial class UserGroup : HeuristicLab.Clients.Access.UserGroupBase {
     847
     848    [System.Runtime.Serialization.OptionalFieldAttribute()]
     849    private string NameField;
     850
     851    [System.Runtime.Serialization.DataMemberAttribute()]
     852    public string Name {
     853      get {
     854        return this.NameField;
     855      }
     856      set {
     857        if ((object.ReferenceEquals(this.NameField, value) != true)) {
     858          this.NameField = value;
     859          this.RaisePropertyChanged("Name");
     860        }
     861      }
     862    }
     863  }
     864
     865  [System.Diagnostics.DebuggerStepThroughAttribute()]
     866  [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
    825867  [System.Runtime.Serialization.DataContractAttribute(Name = "LightweightUser", Namespace = "http://schemas.datacontract.org/2004/07/HeuristicLab.Services.Access.DataTransfer" +
    826868      "")]
     
    856898          this.UserNameField = value;
    857899          this.RaisePropertyChanged("UserName");
    858         }
    859       }
    860     }
    861   }
    862 
    863   [System.Diagnostics.DebuggerStepThroughAttribute()]
    864   [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
    865   [System.Runtime.Serialization.DataContractAttribute(Name = "UserGroup", Namespace = "http://schemas.datacontract.org/2004/07/HeuristicLab.Services.Access.DataTransfer" +
    866       "")]
    867   [System.SerializableAttribute()]
    868   public partial class UserGroup : HeuristicLab.Clients.Access.UserGroupBase {
    869 
    870     [System.Runtime.Serialization.OptionalFieldAttribute()]
    871     private string NameField;
    872 
    873     [System.Runtime.Serialization.DataMemberAttribute()]
    874     public string Name {
    875       get {
    876         return this.NameField;
    877       }
    878       set {
    879         if ((object.ReferenceEquals(this.NameField, value) != true)) {
    880           this.NameField = value;
    881           this.RaisePropertyChanged("Name");
    882900        }
    883901      }
  • branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/UserInformation.cs

    r7436 r7534  
    7272    }
    7373
    74     private bool isInitialized = false;
    75 
    76     public static void Initialize() {
    77       if (!Instance.isInitialized) {
    78         FetchUserInformationFromServerAsync();
    79       }
    80     }
    81 
    8274    private UserInformation() {
    83       if (!Instance.isInitialized) {
    84         //this blocks, so there should be anywhere in the Optimizer startup process
    85         //a call to FetchUserInformationFromServerAsync which is non-blocking
    86         FetchUserInformationFromServer();
    87       }
     75      //this blocks, so there should be anywhere in the Optimizer startup process
     76      //a call to FetchUserInformationFromServerAsync which is non-blocking
     77      FetchUserInformationFromServer();
    8878    }
    8979
     
    9686        AccessClient.CallRunCreationService(x => groups = x.GetGroupsOfCurrentUser());
    9787        AccessClient.CallRunCreationService(x => roles = x.GetRolesOfCurrentUser());
     88        errorOccured = false;
     89        userExists = true;
     90        occuredException = null;
    9891      }
    9992      catch (MessageSecurityException e) {
     
    10194        errorOccured = false;
    10295        userExists = false;
    103         isInitialized = true;
    10496        occuredException = e;
    105         return;
    10697      }
    10798      catch (Exception e) {
    10899        errorOccured = true;
    109100        userExists = false;
    110         isInitialized = false;
    111101        occuredException = e;
    112         return;
    113102      }
    114 
    115       errorOccured = false;
    116       userExists = true;
    117       isInitialized = true;
    118       occuredException = null;
    119     }
    120 
    121     private static void FetchUserInformationFromServerAsync() {
    122       throw new NotImplementedException();
    123103    }
    124104
  • branches/ClientUserManagement/HeuristicLab.Services.Access.DataAccess/3.3/ClientManagement.dbml

    r6858 r7534  
    2121        <Column Name="ClientConfigurationId" Type="System.Guid" DbType="UniqueIdentifier" CanBeNull="true" />
    2222        <Column Name="CountryId" Type="System.Guid" DbType="UniqueIdentifier" CanBeNull="true" />
     23        <Column Name="PerformanceValue" Type="System.Double" DbType="real" CanBeNull="true" />
    2324        <Association Name="ClientType_Client" Member="ClientType" ThisKey="ClientTypeId" OtherKey="Id" Type="ClientType" IsForeignKey="true" />
    2425        <Association Name="OperatingSystem_Client" Member="OperatingSystem" ThisKey="OperatingSystemId" OtherKey="Id" Type="OperatingSystem" IsForeignKey="true" />
  • branches/ClientUserManagement/HeuristicLab.Services.Access.DataAccess/3.3/ClientManagement.dbml.layout

    r6858 r7534  
    2929      </nodes>
    3030    </associationConnector>
    31     <classShape Id="c964402f-99b7-4355-b9ad-279a2a7cf692" absoluteBounds="3.75, 2.5, 2, 2.5401025390624996">
     31    <classShape Id="c964402f-99b7-4355-b9ad-279a2a7cf692" absoluteBounds="3.75, 2.5, 2, 2.7324039713541666">
    3232      <DataClassMoniker Name="/ClientManagementDataContext/Client" />
    3333      <nestedChildShapes>
    34         <elementListCompartment Id="8d16a96c-4ba3-4e2b-b267-0cfe5bb174f1" absoluteBounds="3.7650000000000006, 2.96, 1.9700000000000002, 1.9801025390625" name="DataPropertiesCompartment" titleTextColor="Black" itemTextColor="Black" />
     34        <elementListCompartment Id="8d16a96c-4ba3-4e2b-b267-0cfe5bb174f1" absoluteBounds="3.7650000000000006, 2.96, 1.9700000000000002, 2.1724039713541665" name="DataPropertiesCompartment" titleTextColor="Black" itemTextColor="Black" />
    3535      </nestedChildShapes>
    3636    </classShape>
     
    5959      </nestedChildShapes>
    6060    </classShape>
    61     <associationConnector edgePoints="[(5.875 : 2.07859537760417); (5.875 : 2.34875); (8.125 : 2.34875)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     61    <associationConnector edgePoints="[(5.875 : 2.07859537760417); (5.875 : 2.34875); (8.125 : 2.34875)]" fixedFrom="Algorithm" fixedTo="Algorithm">
    6262      <AssociationMoniker Name="/ClientManagementDataContext/Resource/Resource_ClientLog" />
    6363      <nodes>
     
    121121      </nodes>
    122122    </associationConnector>
    123     <associationConnector edgePoints="[(5.90625 : 2.07859537760417); (5.90625 : 6.22199625651042); (5.625 : 6.22199625651042)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     123    <associationConnector edgePoints="[(5.90625 : 2.07859537760417); (5.90625 : 6.22199625651042); (5.625 : 6.22199625651042)]" fixedFrom="Algorithm" fixedTo="Algorithm">
    124124      <AssociationMoniker Name="/ClientManagementDataContext/Resource/Resource_ResourcePlugin" />
    125125      <nodes>
     
    172172      </nodes>
    173173    </associationConnector>
    174     <associationConnector edgePoints="[(2.5 : 1.09699625651042); (4.46848483471003 : 1.09699625651042); (4.46848483471003 : 2.5)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     174    <associationConnector edgePoints="[(2.5 : 1.69399251302083); (2.875 : 2.06899251302083); (2.875 : 4.12102376302084); (3.75 : 4.12102376302084)]" fixedFrom="NotFixed" fixedTo="Algorithm">
    175175      <AssociationMoniker Name="/ClientManagementDataContext/ClientType/ClientType_Client" />
    176176      <nodes>
     
    179179      </nodes>
    180180    </associationConnector>
    181     <associationConnector edgePoints="[(2.5 : 2.72199625651042); (3.75 : 2.72199625651042)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     181    <associationConnector edgePoints="[(2.5 : 2.72199625651042); (2.79166666666667 : 2.72199625651042 : JumpStart); (2.95833333333333 : 2.72199625651042 : JumpEnd); (3.75 : 2.72199625651042)]" fixedFrom="Algorithm" fixedTo="Algorithm">
    182182      <AssociationMoniker Name="/ClientManagementDataContext/OperatingSystem/OperatingSystem_Client" />
    183183      <nodes>
     
    186186      </nodes>
    187187    </associationConnector>
    188     <associationConnector edgePoints="[(2.5 : 3.59699625651042); (3.75 : 3.59699625651042)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     188    <associationConnector edgePoints="[(2.5 : 3.49801188151042); (2.79166666666667 : 3.49801188151042 : JumpStart); (2.95833333333333 : 3.49801188151042 : JumpEnd); (3.75 : 3.49801188151042)]" fixedFrom="Algorithm" fixedTo="Algorithm">
    189189      <AssociationMoniker Name="/ClientManagementDataContext/Country/Country_Client" />
    190190      <nodes>
     
    193193      </nodes>
    194194    </associationConnector>
    195     <associationConnector edgePoints="[(2.5 : 4.64505126953125); (3.75 : 4.64505126953125)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     195    <associationConnector edgePoints="[(2.5 : 4.74120198567708); (3.75 : 4.74120198567708)]" fixedFrom="Algorithm" fixedTo="Algorithm">
    196196      <AssociationMoniker Name="/ClientManagementDataContext/ClientConfiguration/ClientConfiguration_Client" />
    197197      <nodes>
  • branches/ClientUserManagement/HeuristicLab.Services.Access.DataAccess/3.3/ClientManagement.designer.cs

    r6858 r7534  
    33// <auto-generated>
    44//     This code was generated by a tool.
    5 //     Runtime Version:4.0.30319.237
     5//     Runtime Version:4.0.30319.261
    66//
    77//     Changes to this file may cause incorrect behavior and will be lost if
     
    466466    private System.Nullable<System.Guid> _CountryId;
    467467   
     468    private System.Nullable<double> _PerformanceValue;
     469   
    468470    private EntityRef<ClientType> _ClientType;
    469471   
     
    496498    partial void OnCountryIdChanging(System.Nullable<System.Guid> value);
    497499    partial void OnCountryIdChanged();
     500    partial void OnPerformanceValueChanging(System.Nullable<double> value);
     501    partial void OnPerformanceValueChanged();
    498502    #endregion
    499503   
     
    699703          this.SendPropertyChanged("CountryId");
    700704          this.OnCountryIdChanged();
     705        }
     706      }
     707    }
     708   
     709    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PerformanceValue", DbType="real")]
     710    public System.Nullable<double> PerformanceValue
     711    {
     712      get
     713      {
     714        return this._PerformanceValue;
     715      }
     716      set
     717      {
     718        if ((this._PerformanceValue != value))
     719        {
     720          this.OnPerformanceValueChanging(value);
     721          this.SendPropertyChanging();
     722          this._PerformanceValue = value;
     723          this.SendPropertyChanged("PerformanceValue");
     724          this.OnPerformanceValueChanged();
    701725        }
    702726      }
  • branches/ClientUserManagement/HeuristicLab.Services.Access.DataAccess/3.3/SQL Scripts/Initialize ClientManagement.sql

    r6840 r7534  
    294294  [ClientConfigurationId] [uniqueidentifier] NULL,
    295295  [Timestamp] [datetime] NULL,
     296  [PerformanceValue] [real] NULL,
    296297 CONSTRAINT [PK_Resource] PRIMARY KEY CLUSTERED
    297298(
  • branches/ClientUserManagement/HeuristicLab.Services.Access/3.3/Convert.cs

    r7367 r7534  
    200200        NumberOfCores = source.NumberOfCores.GetValueOrDefault(),
    201201        ProcessorType = source.ProcessorType,
     202        PerformanceValue = source.PerformanceValue.GetValueOrDefault(),
    202203        ClientType = ToDto(source.ClientType)
    203204      };
     
    217218        NumberOfCores = source.NumberOfCores,
    218219        ProcessorType = source.ProcessorType,
     220        PerformanceValue = source.PerformanceValue,
    219221        ClientType = ToEntity(source.ClientType)
    220222      };
  • branches/ClientUserManagement/HeuristicLab.Services.Access/3.3/DataTransfer/Client.cs

    r7355 r7534  
    4444    [DataMember]
    4545    public string ProcessorType { get; set; }
     46    [DataMember]
     47    public double PerformanceValue { get; set; }
    4648  }
    4749}
Note: See TracChangeset for help on using the changeset viewer.