Changeset 389 for binary-improvements2/MapRendering/Web/API/AbsRestApi.cs
- Timestamp:
- Aug 7, 2022, 1:11:51 AM (2 years ago)
- Location:
- binary-improvements2
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
binary-improvements2
- Property svn:ignore
-
old new 1 .idea 1 2 bin 2 .idea 3 server-fixes.sln.DotSettings.user
-
- Property svn:ignore
-
binary-improvements2/MapRendering
- Property svn:ignore
-
old new 1 bin 1 2 obj
-
- Property svn:ignore
-
binary-improvements2/MapRendering/Web/API/AbsRestApi.cs
r388 r389 105 105 } 106 106 107 protected bool TryGetJsonField (JSONObject _body, string _fieldName, out int _value) { 108 _value = default; 109 110 if (!_body.TryGetValue (_fieldName, out JSONNode fieldNode)) { 111 return false; 112 } 113 114 if (!(fieldNode is JSONValue valueField)) { 115 return false; 116 } 117 118 try { 119 _value = valueField.AsInt; 120 return true; 121 } catch (Exception) { 122 return false; 123 } 124 } 125 107 126 protected abstract void HandleRestGet (RequestContext _context); 108 127
Note:
See TracChangeset
for help on using the changeset viewer.