- Timestamp:
- 12/11/08 17:20:03 (16 years ago)
- Location:
- trunk/sources/HeuristicLab.Hive.Server.ADODataAccess
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Hive.Server.ADODataAccess/PermissionOwnerAdapter.cs
r972 r976 116 116 117 117 public PermissionOwner GetPermissionOwnerByName(String name) { 118 PermissionOwner permOwner = new PermissionOwner();118 dsHiveServer.PermissionOwnerRow row = null; 119 119 120 dsHiveServer.PermissionOwnerRow row = 121 data.Single<dsHiveServer.PermissionOwnerRow>( 122 r => !r.IsNameNull() && r.Name == name); 120 IEnumerable<dsHiveServer.PermissionOwnerRow> permOwners = 121 from r in 122 data.AsEnumerable<dsHiveServer.PermissionOwnerRow>() 123 where !r.IsNameNull() && r.Name == name 124 select r; 125 126 if (permOwners.Count<dsHiveServer.PermissionOwnerRow>() == 1) 127 row = permOwners.First<dsHiveServer.PermissionOwnerRow>(); 123 128 124 129 if (row != null) { 130 PermissionOwner permOwner = new PermissionOwner(); 125 131 Convert(row, permOwner); 126 132 -
trunk/sources/HeuristicLab.Hive.Server.ADODataAccess/ResourceAdapter.cs
r972 r976 113 113 114 114 public Resource GetResourceByName(string name) { 115 Resource resource = new Resource();115 dsHiveServer.ResourceRow row = null; 116 116 117 dsHiveServer.ResourceRow row = 118 data.Single<dsHiveServer.ResourceRow>( 119 r => !r.IsNameNull() && r.Name == name); 117 IEnumerable<dsHiveServer.ResourceRow> permOwners = 118 from r in 119 data.AsEnumerable<dsHiveServer.ResourceRow>() 120 where !r.IsNameNull() && r.Name == name 121 select r; 122 123 if (permOwners.Count<dsHiveServer.ResourceRow>() == 1) 124 row = permOwners.First<dsHiveServer.ResourceRow>(); 120 125 121 126 if (row != null) { 122 Convert(row, resource); 127 Resource res = new Resource(); 128 Convert(row, res); 123 129 124 return res ource;130 return res; 125 131 } else { 126 132 return null;
Note: See TracChangeset
for help on using the changeset viewer.