- Timestamp:
- 02/28/12 15:46:53 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/UserInformation.cs
r7436 r7534 72 72 } 73 73 74 private bool isInitialized = false;75 76 public static void Initialize() {77 if (!Instance.isInitialized) {78 FetchUserInformationFromServerAsync();79 }80 }81 82 74 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(); 88 78 } 89 79 … … 96 86 AccessClient.CallRunCreationService(x => groups = x.GetGroupsOfCurrentUser()); 97 87 AccessClient.CallRunCreationService(x => roles = x.GetRolesOfCurrentUser()); 88 errorOccured = false; 89 userExists = true; 90 occuredException = null; 98 91 } 99 92 catch (MessageSecurityException e) { … … 101 94 errorOccured = false; 102 95 userExists = false; 103 isInitialized = true;104 96 occuredException = e; 105 return;106 97 } 107 98 catch (Exception e) { 108 99 errorOccured = true; 109 100 userExists = false; 110 isInitialized = false;111 101 occuredException = e; 112 return;113 102 } 114 115 errorOccured = false;116 userExists = true;117 isInitialized = true;118 occuredException = null;119 }120 121 private static void FetchUserInformationFromServerAsync() {122 throw new NotImplementedException();123 103 } 124 104
Note: See TracChangeset
for help on using the changeset viewer.