forked from loafle/openapi-generator-original
removed non-perl update
This commit is contained in:
parent
10e07eaf74
commit
d7315b56dc
@ -1,61 +0,0 @@
|
||||
using System;
|
||||
using System.Text;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.Serialization;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace IO.Swagger.Model {
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
[DataContract]
|
||||
public class ApiResponse {
|
||||
|
||||
|
||||
[DataMember(Name="code", EmitDefaultValue=false)]
|
||||
public int? Code { get; set; }
|
||||
|
||||
|
||||
|
||||
[DataMember(Name="type", EmitDefaultValue=false)]
|
||||
public string Type { get; set; }
|
||||
|
||||
|
||||
|
||||
[DataMember(Name="message", EmitDefaultValue=false)]
|
||||
public string Message { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get the string presentation of the object
|
||||
/// </summary>
|
||||
/// <returns>String presentation of the object</returns>
|
||||
public override string ToString() {
|
||||
var sb = new StringBuilder();
|
||||
sb.Append("class ApiResponse {\n");
|
||||
|
||||
sb.Append(" Code: ").Append(Code).Append("\n");
|
||||
|
||||
sb.Append(" Type: ").Append(Type).Append("\n");
|
||||
|
||||
sb.Append(" Message: ").Append(Message).Append("\n");
|
||||
|
||||
sb.Append("}\n");
|
||||
return sb.ToString();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get the JSON string presentation of the object
|
||||
/// </summary>
|
||||
/// <returns>JSON string presentation of the object</returns>
|
||||
public string ToJson() {
|
||||
return JsonConvert.SerializeObject(this, Formatting.Indented);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -1,64 +0,0 @@
|
||||
package io.swagger.client.model;
|
||||
|
||||
|
||||
import io.swagger.annotations.*;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
|
||||
@ApiModel(description = "")
|
||||
public class ApiResponse {
|
||||
|
||||
private Integer code = null;
|
||||
private String type = null;
|
||||
private String message = null;
|
||||
|
||||
|
||||
/**
|
||||
**/
|
||||
@ApiModelProperty(value = "")
|
||||
@JsonProperty("code")
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
**/
|
||||
@ApiModelProperty(value = "")
|
||||
@JsonProperty("type")
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
**/
|
||||
@ApiModelProperty(value = "")
|
||||
@JsonProperty("message")
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append("class ApiResponse {\n");
|
||||
|
||||
sb.append(" code: ").append(code).append("\n");
|
||||
sb.append(" type: ").append(type).append("\n");
|
||||
sb.append(" message: ").append(message).append("\n");
|
||||
sb.append("}\n");
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import "SWGObject.h"
|
||||
|
||||
|
||||
@protocol SWGApiResponse
|
||||
@end
|
||||
|
||||
@interface SWGApiResponse : SWGObject
|
||||
|
||||
|
||||
@property(nonatomic) NSNumber* code;
|
||||
|
||||
@property(nonatomic) NSString* type;
|
||||
|
||||
@property(nonatomic) NSString* message;
|
||||
|
||||
@end
|
@ -1,22 +0,0 @@
|
||||
#import "SWGApiResponse.h"
|
||||
|
||||
@implementation SWGApiResponse
|
||||
|
||||
+ (JSONKeyMapper *)keyMapper
|
||||
{
|
||||
return [[JSONKeyMapper alloc] initWithDictionary:@{ @"code": @"code", @"type": @"type", @"message": @"message" }];
|
||||
}
|
||||
|
||||
+ (BOOL)propertyIsOptional:(NSString *)propertyName
|
||||
{
|
||||
NSArray *optionalProperties = @[@"code", @"type", @"message"];
|
||||
|
||||
if ([optionalProperties containsObject:propertyName]) {
|
||||
return YES;
|
||||
}
|
||||
else {
|
||||
return NO;
|
||||
}
|
||||
}
|
||||
|
||||
@end
|
Loading…
x
Reference in New Issue
Block a user