InternalNewsProviderImpl Resource

The base provider. All providers should have similar functionality to this. Hopefully these methods are fairly self-explanatory. Think of these as 'tool box' functions to help generate services quickly.

GET /newsFromMike/getNewsById/{newsId}

Request Parameters
name type description constraints
newsId path long
Response Body
media type data type description
application/json InternalNews (JSON)
application/xml internalNews (XML)

Example

Request
GET /newsFromMike/getNewsById/{newsId}
Content-Type: */*
Accept: application/json

                
...
                
              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
{
  "title" : "...",
  "article" : "...",
  "url" : "...",
  "date" : 12345,
  "life" : 12345,
  "id" : 12345,
  "version" : 12345,
  "violations" : [ {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  }, {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  } ]
}
                
              

GET /newsFromMike/getNewsByAmount/{maxResults}/{pageNum}

Request Parameters
name type description constraints
maxResults path int
pageNum path int
Response Body
media type data type description
application/json array of InternalNews (JSON)
application/xml list of internalNews (XML)

Example

Request
GET /newsFromMike/getNewsByAmount/{maxResults}/{pageNum}
Content-Type: */*
Accept: application/json

                
...
                
              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
[ {
  "title" : "...",
  "article" : "...",
  "url" : "...",
  "date" : 12345,
  "life" : 12345,
  "id" : 12345,
  "version" : 12345,
  "violations" : [ {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  }, {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  } ]
} ]