1 // Code generated by go-swagger; DO NOT EDIT.
5 // This file was generated by the swagger tool.
6 // Editing this file might prove futile when you re-run the swagger generate command
12 "github.com/go-openapi/runtime"
13 "github.com/go-openapi/strfmt"
15 "gerrit.o-ran-sc.org/r/ric-plt/xapp-frame/pkg/clientmodel"
18 // GetAllSubscriptionsReader is a Reader for the GetAllSubscriptions structure.
19 type GetAllSubscriptionsReader struct {
20 formats strfmt.Registry
23 // ReadResponse reads a server response into the received o.
24 func (o *GetAllSubscriptionsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
25 switch response.Code() {
27 result := NewGetAllSubscriptionsOK()
28 if err := result.readResponse(response, consumer, o.formats); err != nil {
33 result := NewGetAllSubscriptionsInternalServerError()
34 if err := result.readResponse(response, consumer, o.formats); err != nil {
40 return nil, runtime.NewAPIError("unknown error", response, response.Code())
44 // NewGetAllSubscriptionsOK creates a GetAllSubscriptionsOK with default headers values
45 func NewGetAllSubscriptionsOK() *GetAllSubscriptionsOK {
46 return &GetAllSubscriptionsOK{}
49 /*GetAllSubscriptionsOK handles this case with default header values.
51 successful query of subscriptions
53 type GetAllSubscriptionsOK struct {
54 Payload clientmodel.SubscriptionList
57 func (o *GetAllSubscriptionsOK) Error() string {
58 return fmt.Sprintf("[GET /subscriptions][%d] getAllSubscriptionsOK %+v", 200, o.Payload)
61 func (o *GetAllSubscriptionsOK) GetPayload() clientmodel.SubscriptionList {
65 func (o *GetAllSubscriptionsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
68 if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF {
75 // NewGetAllSubscriptionsInternalServerError creates a GetAllSubscriptionsInternalServerError with default headers values
76 func NewGetAllSubscriptionsInternalServerError() *GetAllSubscriptionsInternalServerError {
77 return &GetAllSubscriptionsInternalServerError{}
80 /*GetAllSubscriptionsInternalServerError handles this case with default header values.
84 type GetAllSubscriptionsInternalServerError struct {
87 func (o *GetAllSubscriptionsInternalServerError) Error() string {
88 return fmt.Sprintf("[GET /subscriptions][%d] getAllSubscriptionsInternalServerError ", 500)
91 func (o *GetAllSubscriptionsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {