You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
605 B

  1. package requests
  2. import "io"
  3. type CommonRequest struct {
  4. *baseRequest
  5. Product string
  6. Ontology AcsRequest
  7. }
  8. func (request *CommonRequest) TransToAscRequest() {
  9. httpReqeust := &HttpRequest{}
  10. httpReqeust.baseRequest = request.baseRequest
  11. httpReqeust.product = request.Product
  12. request.Ontology = httpReqeust
  13. }
  14. func (request *CommonRequest) BuildUrl() string {
  15. return request.Ontology.BuildUrl()
  16. }
  17. func (request *CommonRequest) BuildQueries() string {
  18. return request.Ontology.BuildQueries()
  19. }
  20. func (request *CommonRequest) GetBodyReader() io.Reader {
  21. return request.Ontology.GetBodyReader()
  22. }