From e424d0c1dff2208ee97a21633b3caec6860a07cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francisco=20Ortiz=20Pe=C3=B1aloza?= <90245+fortizpenaloza@users.noreply.github.com> Date: Mon, 1 Jul 2019 12:13:58 -0300 Subject: [PATCH 1/2] Deleted class definitions From 735f29a961afaddf8d2e03b3721bc33bae5ebe61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francisco=20Ortiz=20Pe=C3=B1aloza?= <90245+fortizpenaloza@users.noreply.github.com> Date: Mon, 1 Jul 2019 12:17:26 -0300 Subject: [PATCH 2/2] Deleted both class definitions --- .../Stargate-Model/HTTPClientError.class.st | 17 ---------- .../Stargate-Model/HTTPNotAcceptable.class.st | 32 ------------------- 2 files changed, 49 deletions(-) delete mode 100644 source/Stargate-Model/HTTPClientError.class.st delete mode 100644 source/Stargate-Model/HTTPNotAcceptable.class.st diff --git a/source/Stargate-Model/HTTPClientError.class.st b/source/Stargate-Model/HTTPClientError.class.st deleted file mode 100644 index 48af0c1..0000000 --- a/source/Stargate-Model/HTTPClientError.class.st +++ /dev/null @@ -1,17 +0,0 @@ -" -I'm an exception expecting to be raised when someone makes an incorrect HTTP request. -" -Class { - #name : #HTTPClientError, - #superclass : #Error, - #category : #'Stargate-Model-Controllers' -} - -{ #category : #'*Stargate-Model' } -HTTPClientError >> neoJsonOn: neoJSONWriter [ - - neoJSONWriter - writeMap: - {(#code -> self code). - (#message -> self messageText)} asDictionary -] diff --git a/source/Stargate-Model/HTTPNotAcceptable.class.st b/source/Stargate-Model/HTTPNotAcceptable.class.st deleted file mode 100644 index e5a942c..0000000 --- a/source/Stargate-Model/HTTPNotAcceptable.class.st +++ /dev/null @@ -1,32 +0,0 @@ -" -I represent an HTTP client error: - -406 Not Acceptable - -The resource identified by the request is only capable of generating response entities which have content characteristics not acceptable according to the accept headers sent in the request. - -Unless it was a HEAD request, the response SHOULD include an entity containing a list of available entity characteristics and location(s) from which the user or user agent can choose the one most appropriate. The entity format is specified by the media type given in the Content-Type header field. Depending upon the format and the capabilities of the user agent, selection of the most appropriate choice MAY be performed automatically. However, this specification does not define any standard for such automatic selection. - - Note: HTTP/1.1 servers are allowed to return responses which are not acceptable according to the accept headers sent in the request. In some cases, this may even be preferable to sending a 406 response. User agents are encouraged to inspect the headers of an incoming response to determine if it is acceptable. - -If the response could be unacceptable, a user agent SHOULD temporarily stop receipt of more data and query the user for a decision on further actions. -" -Class { - #name : #HTTPNotAcceptable, - #superclass : #HTTPClientError, - #instVars : [ - 'allowedMediaTypes' - ], - #category : #'Stargate-Model-Controllers' -} - -{ #category : #'*Stargate-Model' } -HTTPNotAcceptable >> neoJsonOn: neoJSONWriter [ - - (neoJSONWriter customMappingFor: ZnMimeType) encoder: [ :mediaType | mediaType asString ]. - neoJSONWriter - writeMap: - {(#code -> self code). - (#message -> self messageText). - (#allowedMediaTypes -> self allowedMediaTypes)} asDictionary -]