...

Source file src/go.formulabun.club/translator/client/model_server_info.go

Documentation: go.formulabun.club/translator/client

     1  /*
     2  Translator service between a srb2kart server and json
     3  
     4  No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
     5  
     6  API version: 0.0.1
     7  */
     8  
     9  // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
    10  
    11  package openapi
    12  
    13  import (
    14  	"encoding/json"
    15  )
    16  
    17  // ServerInfo struct for ServerInfo
    18  type ServerInfo struct {
    19  	PacketVersion *float32 `json:"PacketVersion,omitempty"`
    20  	Application *string `json:"Application,omitempty"`
    21  	Version *float32 `json:"Version,omitempty"`
    22  	SubVersion *float32 `json:"SubVersion,omitempty"`
    23  	NumberOfPlayer *float32 `json:"NumberOfPlayer,omitempty"`
    24  	MaxPlayers *float32 `json:"MaxPlayers,omitempty"`
    25  	GameType *float32 `json:"GameType,omitempty"`
    26  	ModifiedGame *bool `json:"ModifiedGame,omitempty"`
    27  	CheatsEnabled *bool `json:"CheatsEnabled,omitempty"`
    28  	KartVars *float32 `json:"KartVars,omitempty"`
    29  	FileNeededNum *float32 `json:"FileNeededNum,omitempty"`
    30  	Time *float32 `json:"Time,omitempty"`
    31  	LevelTime *float32 `json:"LevelTime,omitempty"`
    32  	ServerNameRaw *string `json:"ServerNameRaw,omitempty"`
    33  	ServerName *string `json:"ServerName,omitempty"`
    34  	MapName *string `json:"MapName,omitempty"`
    35  	MapTitle *string `json:"MapTitle,omitempty"`
    36  	MapMD5 []float32 `json:"MapMD5,omitempty"`
    37  	ActNum *float32 `json:"ActNum,omitempty"`
    38  	IsZone *bool `json:"IsZone,omitempty"`
    39  	HttpSource *string `json:"HttpSource,omitempty"`
    40  	FileNeeded []FileNeededInner `json:"FileNeeded,omitempty"`
    41  }
    42  
    43  // NewServerInfo instantiates a new ServerInfo object
    44  // This constructor will assign default values to properties that have it defined,
    45  // and makes sure properties required by API are set, but the set of arguments
    46  // will change when the set of required properties is changed
    47  func NewServerInfo() *ServerInfo {
    48  	this := ServerInfo{}
    49  	return &this
    50  }
    51  
    52  // NewServerInfoWithDefaults instantiates a new ServerInfo object
    53  // This constructor will only assign default values to properties that have it defined,
    54  // but it doesn't guarantee that properties required by API are set
    55  func NewServerInfoWithDefaults() *ServerInfo {
    56  	this := ServerInfo{}
    57  	return &this
    58  }
    59  
    60  // GetPacketVersion returns the PacketVersion field value if set, zero value otherwise.
    61  func (o *ServerInfo) GetPacketVersion() float32 {
    62  	if o == nil || o.PacketVersion == nil {
    63  		var ret float32
    64  		return ret
    65  	}
    66  	return *o.PacketVersion
    67  }
    68  
    69  // GetPacketVersionOk returns a tuple with the PacketVersion field value if set, nil otherwise
    70  // and a boolean to check if the value has been set.
    71  func (o *ServerInfo) GetPacketVersionOk() (*float32, bool) {
    72  	if o == nil || o.PacketVersion == nil {
    73  		return nil, false
    74  	}
    75  	return o.PacketVersion, true
    76  }
    77  
    78  // HasPacketVersion returns a boolean if a field has been set.
    79  func (o *ServerInfo) HasPacketVersion() bool {
    80  	if o != nil && o.PacketVersion != nil {
    81  		return true
    82  	}
    83  
    84  	return false
    85  }
    86  
    87  // SetPacketVersion gets a reference to the given float32 and assigns it to the PacketVersion field.
    88  func (o *ServerInfo) SetPacketVersion(v float32) {
    89  	o.PacketVersion = &v
    90  }
    91  
    92  // GetApplication returns the Application field value if set, zero value otherwise.
    93  func (o *ServerInfo) GetApplication() string {
    94  	if o == nil || o.Application == nil {
    95  		var ret string
    96  		return ret
    97  	}
    98  	return *o.Application
    99  }
   100  
   101  // GetApplicationOk returns a tuple with the Application field value if set, nil otherwise
   102  // and a boolean to check if the value has been set.
   103  func (o *ServerInfo) GetApplicationOk() (*string, bool) {
   104  	if o == nil || o.Application == nil {
   105  		return nil, false
   106  	}
   107  	return o.Application, true
   108  }
   109  
   110  // HasApplication returns a boolean if a field has been set.
   111  func (o *ServerInfo) HasApplication() bool {
   112  	if o != nil && o.Application != nil {
   113  		return true
   114  	}
   115  
   116  	return false
   117  }
   118  
   119  // SetApplication gets a reference to the given string and assigns it to the Application field.
   120  func (o *ServerInfo) SetApplication(v string) {
   121  	o.Application = &v
   122  }
   123  
   124  // GetVersion returns the Version field value if set, zero value otherwise.
   125  func (o *ServerInfo) GetVersion() float32 {
   126  	if o == nil || o.Version == nil {
   127  		var ret float32
   128  		return ret
   129  	}
   130  	return *o.Version
   131  }
   132  
   133  // GetVersionOk returns a tuple with the Version field value if set, nil otherwise
   134  // and a boolean to check if the value has been set.
   135  func (o *ServerInfo) GetVersionOk() (*float32, bool) {
   136  	if o == nil || o.Version == nil {
   137  		return nil, false
   138  	}
   139  	return o.Version, true
   140  }
   141  
   142  // HasVersion returns a boolean if a field has been set.
   143  func (o *ServerInfo) HasVersion() bool {
   144  	if o != nil && o.Version != nil {
   145  		return true
   146  	}
   147  
   148  	return false
   149  }
   150  
   151  // SetVersion gets a reference to the given float32 and assigns it to the Version field.
   152  func (o *ServerInfo) SetVersion(v float32) {
   153  	o.Version = &v
   154  }
   155  
   156  // GetSubVersion returns the SubVersion field value if set, zero value otherwise.
   157  func (o *ServerInfo) GetSubVersion() float32 {
   158  	if o == nil || o.SubVersion == nil {
   159  		var ret float32
   160  		return ret
   161  	}
   162  	return *o.SubVersion
   163  }
   164  
   165  // GetSubVersionOk returns a tuple with the SubVersion field value if set, nil otherwise
   166  // and a boolean to check if the value has been set.
   167  func (o *ServerInfo) GetSubVersionOk() (*float32, bool) {
   168  	if o == nil || o.SubVersion == nil {
   169  		return nil, false
   170  	}
   171  	return o.SubVersion, true
   172  }
   173  
   174  // HasSubVersion returns a boolean if a field has been set.
   175  func (o *ServerInfo) HasSubVersion() bool {
   176  	if o != nil && o.SubVersion != nil {
   177  		return true
   178  	}
   179  
   180  	return false
   181  }
   182  
   183  // SetSubVersion gets a reference to the given float32 and assigns it to the SubVersion field.
   184  func (o *ServerInfo) SetSubVersion(v float32) {
   185  	o.SubVersion = &v
   186  }
   187  
   188  // GetNumberOfPlayer returns the NumberOfPlayer field value if set, zero value otherwise.
   189  func (o *ServerInfo) GetNumberOfPlayer() float32 {
   190  	if o == nil || o.NumberOfPlayer == nil {
   191  		var ret float32
   192  		return ret
   193  	}
   194  	return *o.NumberOfPlayer
   195  }
   196  
   197  // GetNumberOfPlayerOk returns a tuple with the NumberOfPlayer field value if set, nil otherwise
   198  // and a boolean to check if the value has been set.
   199  func (o *ServerInfo) GetNumberOfPlayerOk() (*float32, bool) {
   200  	if o == nil || o.NumberOfPlayer == nil {
   201  		return nil, false
   202  	}
   203  	return o.NumberOfPlayer, true
   204  }
   205  
   206  // HasNumberOfPlayer returns a boolean if a field has been set.
   207  func (o *ServerInfo) HasNumberOfPlayer() bool {
   208  	if o != nil && o.NumberOfPlayer != nil {
   209  		return true
   210  	}
   211  
   212  	return false
   213  }
   214  
   215  // SetNumberOfPlayer gets a reference to the given float32 and assigns it to the NumberOfPlayer field.
   216  func (o *ServerInfo) SetNumberOfPlayer(v float32) {
   217  	o.NumberOfPlayer = &v
   218  }
   219  
   220  // GetMaxPlayers returns the MaxPlayers field value if set, zero value otherwise.
   221  func (o *ServerInfo) GetMaxPlayers() float32 {
   222  	if o == nil || o.MaxPlayers == nil {
   223  		var ret float32
   224  		return ret
   225  	}
   226  	return *o.MaxPlayers
   227  }
   228  
   229  // GetMaxPlayersOk returns a tuple with the MaxPlayers field value if set, nil otherwise
   230  // and a boolean to check if the value has been set.
   231  func (o *ServerInfo) GetMaxPlayersOk() (*float32, bool) {
   232  	if o == nil || o.MaxPlayers == nil {
   233  		return nil, false
   234  	}
   235  	return o.MaxPlayers, true
   236  }
   237  
   238  // HasMaxPlayers returns a boolean if a field has been set.
   239  func (o *ServerInfo) HasMaxPlayers() bool {
   240  	if o != nil && o.MaxPlayers != nil {
   241  		return true
   242  	}
   243  
   244  	return false
   245  }
   246  
   247  // SetMaxPlayers gets a reference to the given float32 and assigns it to the MaxPlayers field.
   248  func (o *ServerInfo) SetMaxPlayers(v float32) {
   249  	o.MaxPlayers = &v
   250  }
   251  
   252  // GetGameType returns the GameType field value if set, zero value otherwise.
   253  func (o *ServerInfo) GetGameType() float32 {
   254  	if o == nil || o.GameType == nil {
   255  		var ret float32
   256  		return ret
   257  	}
   258  	return *o.GameType
   259  }
   260  
   261  // GetGameTypeOk returns a tuple with the GameType field value if set, nil otherwise
   262  // and a boolean to check if the value has been set.
   263  func (o *ServerInfo) GetGameTypeOk() (*float32, bool) {
   264  	if o == nil || o.GameType == nil {
   265  		return nil, false
   266  	}
   267  	return o.GameType, true
   268  }
   269  
   270  // HasGameType returns a boolean if a field has been set.
   271  func (o *ServerInfo) HasGameType() bool {
   272  	if o != nil && o.GameType != nil {
   273  		return true
   274  	}
   275  
   276  	return false
   277  }
   278  
   279  // SetGameType gets a reference to the given float32 and assigns it to the GameType field.
   280  func (o *ServerInfo) SetGameType(v float32) {
   281  	o.GameType = &v
   282  }
   283  
   284  // GetModifiedGame returns the ModifiedGame field value if set, zero value otherwise.
   285  func (o *ServerInfo) GetModifiedGame() bool {
   286  	if o == nil || o.ModifiedGame == nil {
   287  		var ret bool
   288  		return ret
   289  	}
   290  	return *o.ModifiedGame
   291  }
   292  
   293  // GetModifiedGameOk returns a tuple with the ModifiedGame field value if set, nil otherwise
   294  // and a boolean to check if the value has been set.
   295  func (o *ServerInfo) GetModifiedGameOk() (*bool, bool) {
   296  	if o == nil || o.ModifiedGame == nil {
   297  		return nil, false
   298  	}
   299  	return o.ModifiedGame, true
   300  }
   301  
   302  // HasModifiedGame returns a boolean if a field has been set.
   303  func (o *ServerInfo) HasModifiedGame() bool {
   304  	if o != nil && o.ModifiedGame != nil {
   305  		return true
   306  	}
   307  
   308  	return false
   309  }
   310  
   311  // SetModifiedGame gets a reference to the given bool and assigns it to the ModifiedGame field.
   312  func (o *ServerInfo) SetModifiedGame(v bool) {
   313  	o.ModifiedGame = &v
   314  }
   315  
   316  // GetCheatsEnabled returns the CheatsEnabled field value if set, zero value otherwise.
   317  func (o *ServerInfo) GetCheatsEnabled() bool {
   318  	if o == nil || o.CheatsEnabled == nil {
   319  		var ret bool
   320  		return ret
   321  	}
   322  	return *o.CheatsEnabled
   323  }
   324  
   325  // GetCheatsEnabledOk returns a tuple with the CheatsEnabled field value if set, nil otherwise
   326  // and a boolean to check if the value has been set.
   327  func (o *ServerInfo) GetCheatsEnabledOk() (*bool, bool) {
   328  	if o == nil || o.CheatsEnabled == nil {
   329  		return nil, false
   330  	}
   331  	return o.CheatsEnabled, true
   332  }
   333  
   334  // HasCheatsEnabled returns a boolean if a field has been set.
   335  func (o *ServerInfo) HasCheatsEnabled() bool {
   336  	if o != nil && o.CheatsEnabled != nil {
   337  		return true
   338  	}
   339  
   340  	return false
   341  }
   342  
   343  // SetCheatsEnabled gets a reference to the given bool and assigns it to the CheatsEnabled field.
   344  func (o *ServerInfo) SetCheatsEnabled(v bool) {
   345  	o.CheatsEnabled = &v
   346  }
   347  
   348  // GetKartVars returns the KartVars field value if set, zero value otherwise.
   349  func (o *ServerInfo) GetKartVars() float32 {
   350  	if o == nil || o.KartVars == nil {
   351  		var ret float32
   352  		return ret
   353  	}
   354  	return *o.KartVars
   355  }
   356  
   357  // GetKartVarsOk returns a tuple with the KartVars field value if set, nil otherwise
   358  // and a boolean to check if the value has been set.
   359  func (o *ServerInfo) GetKartVarsOk() (*float32, bool) {
   360  	if o == nil || o.KartVars == nil {
   361  		return nil, false
   362  	}
   363  	return o.KartVars, true
   364  }
   365  
   366  // HasKartVars returns a boolean if a field has been set.
   367  func (o *ServerInfo) HasKartVars() bool {
   368  	if o != nil && o.KartVars != nil {
   369  		return true
   370  	}
   371  
   372  	return false
   373  }
   374  
   375  // SetKartVars gets a reference to the given float32 and assigns it to the KartVars field.
   376  func (o *ServerInfo) SetKartVars(v float32) {
   377  	o.KartVars = &v
   378  }
   379  
   380  // GetFileNeededNum returns the FileNeededNum field value if set, zero value otherwise.
   381  func (o *ServerInfo) GetFileNeededNum() float32 {
   382  	if o == nil || o.FileNeededNum == nil {
   383  		var ret float32
   384  		return ret
   385  	}
   386  	return *o.FileNeededNum
   387  }
   388  
   389  // GetFileNeededNumOk returns a tuple with the FileNeededNum field value if set, nil otherwise
   390  // and a boolean to check if the value has been set.
   391  func (o *ServerInfo) GetFileNeededNumOk() (*float32, bool) {
   392  	if o == nil || o.FileNeededNum == nil {
   393  		return nil, false
   394  	}
   395  	return o.FileNeededNum, true
   396  }
   397  
   398  // HasFileNeededNum returns a boolean if a field has been set.
   399  func (o *ServerInfo) HasFileNeededNum() bool {
   400  	if o != nil && o.FileNeededNum != nil {
   401  		return true
   402  	}
   403  
   404  	return false
   405  }
   406  
   407  // SetFileNeededNum gets a reference to the given float32 and assigns it to the FileNeededNum field.
   408  func (o *ServerInfo) SetFileNeededNum(v float32) {
   409  	o.FileNeededNum = &v
   410  }
   411  
   412  // GetTime returns the Time field value if set, zero value otherwise.
   413  func (o *ServerInfo) GetTime() float32 {
   414  	if o == nil || o.Time == nil {
   415  		var ret float32
   416  		return ret
   417  	}
   418  	return *o.Time
   419  }
   420  
   421  // GetTimeOk returns a tuple with the Time field value if set, nil otherwise
   422  // and a boolean to check if the value has been set.
   423  func (o *ServerInfo) GetTimeOk() (*float32, bool) {
   424  	if o == nil || o.Time == nil {
   425  		return nil, false
   426  	}
   427  	return o.Time, true
   428  }
   429  
   430  // HasTime returns a boolean if a field has been set.
   431  func (o *ServerInfo) HasTime() bool {
   432  	if o != nil && o.Time != nil {
   433  		return true
   434  	}
   435  
   436  	return false
   437  }
   438  
   439  // SetTime gets a reference to the given float32 and assigns it to the Time field.
   440  func (o *ServerInfo) SetTime(v float32) {
   441  	o.Time = &v
   442  }
   443  
   444  // GetLevelTime returns the LevelTime field value if set, zero value otherwise.
   445  func (o *ServerInfo) GetLevelTime() float32 {
   446  	if o == nil || o.LevelTime == nil {
   447  		var ret float32
   448  		return ret
   449  	}
   450  	return *o.LevelTime
   451  }
   452  
   453  // GetLevelTimeOk returns a tuple with the LevelTime field value if set, nil otherwise
   454  // and a boolean to check if the value has been set.
   455  func (o *ServerInfo) GetLevelTimeOk() (*float32, bool) {
   456  	if o == nil || o.LevelTime == nil {
   457  		return nil, false
   458  	}
   459  	return o.LevelTime, true
   460  }
   461  
   462  // HasLevelTime returns a boolean if a field has been set.
   463  func (o *ServerInfo) HasLevelTime() bool {
   464  	if o != nil && o.LevelTime != nil {
   465  		return true
   466  	}
   467  
   468  	return false
   469  }
   470  
   471  // SetLevelTime gets a reference to the given float32 and assigns it to the LevelTime field.
   472  func (o *ServerInfo) SetLevelTime(v float32) {
   473  	o.LevelTime = &v
   474  }
   475  
   476  // GetServerNameRaw returns the ServerNameRaw field value if set, zero value otherwise.
   477  func (o *ServerInfo) GetServerNameRaw() string {
   478  	if o == nil || o.ServerNameRaw == nil {
   479  		var ret string
   480  		return ret
   481  	}
   482  	return *o.ServerNameRaw
   483  }
   484  
   485  // GetServerNameRawOk returns a tuple with the ServerNameRaw field value if set, nil otherwise
   486  // and a boolean to check if the value has been set.
   487  func (o *ServerInfo) GetServerNameRawOk() (*string, bool) {
   488  	if o == nil || o.ServerNameRaw == nil {
   489  		return nil, false
   490  	}
   491  	return o.ServerNameRaw, true
   492  }
   493  
   494  // HasServerNameRaw returns a boolean if a field has been set.
   495  func (o *ServerInfo) HasServerNameRaw() bool {
   496  	if o != nil && o.ServerNameRaw != nil {
   497  		return true
   498  	}
   499  
   500  	return false
   501  }
   502  
   503  // SetServerNameRaw gets a reference to the given string and assigns it to the ServerNameRaw field.
   504  func (o *ServerInfo) SetServerNameRaw(v string) {
   505  	o.ServerNameRaw = &v
   506  }
   507  
   508  // GetServerName returns the ServerName field value if set, zero value otherwise.
   509  func (o *ServerInfo) GetServerName() string {
   510  	if o == nil || o.ServerName == nil {
   511  		var ret string
   512  		return ret
   513  	}
   514  	return *o.ServerName
   515  }
   516  
   517  // GetServerNameOk returns a tuple with the ServerName field value if set, nil otherwise
   518  // and a boolean to check if the value has been set.
   519  func (o *ServerInfo) GetServerNameOk() (*string, bool) {
   520  	if o == nil || o.ServerName == nil {
   521  		return nil, false
   522  	}
   523  	return o.ServerName, true
   524  }
   525  
   526  // HasServerName returns a boolean if a field has been set.
   527  func (o *ServerInfo) HasServerName() bool {
   528  	if o != nil && o.ServerName != nil {
   529  		return true
   530  	}
   531  
   532  	return false
   533  }
   534  
   535  // SetServerName gets a reference to the given string and assigns it to the ServerName field.
   536  func (o *ServerInfo) SetServerName(v string) {
   537  	o.ServerName = &v
   538  }
   539  
   540  // GetMapName returns the MapName field value if set, zero value otherwise.
   541  func (o *ServerInfo) GetMapName() string {
   542  	if o == nil || o.MapName == nil {
   543  		var ret string
   544  		return ret
   545  	}
   546  	return *o.MapName
   547  }
   548  
   549  // GetMapNameOk returns a tuple with the MapName field value if set, nil otherwise
   550  // and a boolean to check if the value has been set.
   551  func (o *ServerInfo) GetMapNameOk() (*string, bool) {
   552  	if o == nil || o.MapName == nil {
   553  		return nil, false
   554  	}
   555  	return o.MapName, true
   556  }
   557  
   558  // HasMapName returns a boolean if a field has been set.
   559  func (o *ServerInfo) HasMapName() bool {
   560  	if o != nil && o.MapName != nil {
   561  		return true
   562  	}
   563  
   564  	return false
   565  }
   566  
   567  // SetMapName gets a reference to the given string and assigns it to the MapName field.
   568  func (o *ServerInfo) SetMapName(v string) {
   569  	o.MapName = &v
   570  }
   571  
   572  // GetMapTitle returns the MapTitle field value if set, zero value otherwise.
   573  func (o *ServerInfo) GetMapTitle() string {
   574  	if o == nil || o.MapTitle == nil {
   575  		var ret string
   576  		return ret
   577  	}
   578  	return *o.MapTitle
   579  }
   580  
   581  // GetMapTitleOk returns a tuple with the MapTitle field value if set, nil otherwise
   582  // and a boolean to check if the value has been set.
   583  func (o *ServerInfo) GetMapTitleOk() (*string, bool) {
   584  	if o == nil || o.MapTitle == nil {
   585  		return nil, false
   586  	}
   587  	return o.MapTitle, true
   588  }
   589  
   590  // HasMapTitle returns a boolean if a field has been set.
   591  func (o *ServerInfo) HasMapTitle() bool {
   592  	if o != nil && o.MapTitle != nil {
   593  		return true
   594  	}
   595  
   596  	return false
   597  }
   598  
   599  // SetMapTitle gets a reference to the given string and assigns it to the MapTitle field.
   600  func (o *ServerInfo) SetMapTitle(v string) {
   601  	o.MapTitle = &v
   602  }
   603  
   604  // GetMapMD5 returns the MapMD5 field value if set, zero value otherwise.
   605  func (o *ServerInfo) GetMapMD5() []float32 {
   606  	if o == nil || o.MapMD5 == nil {
   607  		var ret []float32
   608  		return ret
   609  	}
   610  	return o.MapMD5
   611  }
   612  
   613  // GetMapMD5Ok returns a tuple with the MapMD5 field value if set, nil otherwise
   614  // and a boolean to check if the value has been set.
   615  func (o *ServerInfo) GetMapMD5Ok() ([]float32, bool) {
   616  	if o == nil || o.MapMD5 == nil {
   617  		return nil, false
   618  	}
   619  	return o.MapMD5, true
   620  }
   621  
   622  // HasMapMD5 returns a boolean if a field has been set.
   623  func (o *ServerInfo) HasMapMD5() bool {
   624  	if o != nil && o.MapMD5 != nil {
   625  		return true
   626  	}
   627  
   628  	return false
   629  }
   630  
   631  // SetMapMD5 gets a reference to the given []float32 and assigns it to the MapMD5 field.
   632  func (o *ServerInfo) SetMapMD5(v []float32) {
   633  	o.MapMD5 = v
   634  }
   635  
   636  // GetActNum returns the ActNum field value if set, zero value otherwise.
   637  func (o *ServerInfo) GetActNum() float32 {
   638  	if o == nil || o.ActNum == nil {
   639  		var ret float32
   640  		return ret
   641  	}
   642  	return *o.ActNum
   643  }
   644  
   645  // GetActNumOk returns a tuple with the ActNum field value if set, nil otherwise
   646  // and a boolean to check if the value has been set.
   647  func (o *ServerInfo) GetActNumOk() (*float32, bool) {
   648  	if o == nil || o.ActNum == nil {
   649  		return nil, false
   650  	}
   651  	return o.ActNum, true
   652  }
   653  
   654  // HasActNum returns a boolean if a field has been set.
   655  func (o *ServerInfo) HasActNum() bool {
   656  	if o != nil && o.ActNum != nil {
   657  		return true
   658  	}
   659  
   660  	return false
   661  }
   662  
   663  // SetActNum gets a reference to the given float32 and assigns it to the ActNum field.
   664  func (o *ServerInfo) SetActNum(v float32) {
   665  	o.ActNum = &v
   666  }
   667  
   668  // GetIsZone returns the IsZone field value if set, zero value otherwise.
   669  func (o *ServerInfo) GetIsZone() bool {
   670  	if o == nil || o.IsZone == nil {
   671  		var ret bool
   672  		return ret
   673  	}
   674  	return *o.IsZone
   675  }
   676  
   677  // GetIsZoneOk returns a tuple with the IsZone field value if set, nil otherwise
   678  // and a boolean to check if the value has been set.
   679  func (o *ServerInfo) GetIsZoneOk() (*bool, bool) {
   680  	if o == nil || o.IsZone == nil {
   681  		return nil, false
   682  	}
   683  	return o.IsZone, true
   684  }
   685  
   686  // HasIsZone returns a boolean if a field has been set.
   687  func (o *ServerInfo) HasIsZone() bool {
   688  	if o != nil && o.IsZone != nil {
   689  		return true
   690  	}
   691  
   692  	return false
   693  }
   694  
   695  // SetIsZone gets a reference to the given bool and assigns it to the IsZone field.
   696  func (o *ServerInfo) SetIsZone(v bool) {
   697  	o.IsZone = &v
   698  }
   699  
   700  // GetHttpSource returns the HttpSource field value if set, zero value otherwise.
   701  func (o *ServerInfo) GetHttpSource() string {
   702  	if o == nil || o.HttpSource == nil {
   703  		var ret string
   704  		return ret
   705  	}
   706  	return *o.HttpSource
   707  }
   708  
   709  // GetHttpSourceOk returns a tuple with the HttpSource field value if set, nil otherwise
   710  // and a boolean to check if the value has been set.
   711  func (o *ServerInfo) GetHttpSourceOk() (*string, bool) {
   712  	if o == nil || o.HttpSource == nil {
   713  		return nil, false
   714  	}
   715  	return o.HttpSource, true
   716  }
   717  
   718  // HasHttpSource returns a boolean if a field has been set.
   719  func (o *ServerInfo) HasHttpSource() bool {
   720  	if o != nil && o.HttpSource != nil {
   721  		return true
   722  	}
   723  
   724  	return false
   725  }
   726  
   727  // SetHttpSource gets a reference to the given string and assigns it to the HttpSource field.
   728  func (o *ServerInfo) SetHttpSource(v string) {
   729  	o.HttpSource = &v
   730  }
   731  
   732  // GetFileNeeded returns the FileNeeded field value if set, zero value otherwise.
   733  func (o *ServerInfo) GetFileNeeded() []FileNeededInner {
   734  	if o == nil || o.FileNeeded == nil {
   735  		var ret []FileNeededInner
   736  		return ret
   737  	}
   738  	return o.FileNeeded
   739  }
   740  
   741  // GetFileNeededOk returns a tuple with the FileNeeded field value if set, nil otherwise
   742  // and a boolean to check if the value has been set.
   743  func (o *ServerInfo) GetFileNeededOk() ([]FileNeededInner, bool) {
   744  	if o == nil || o.FileNeeded == nil {
   745  		return nil, false
   746  	}
   747  	return o.FileNeeded, true
   748  }
   749  
   750  // HasFileNeeded returns a boolean if a field has been set.
   751  func (o *ServerInfo) HasFileNeeded() bool {
   752  	if o != nil && o.FileNeeded != nil {
   753  		return true
   754  	}
   755  
   756  	return false
   757  }
   758  
   759  // SetFileNeeded gets a reference to the given []FileNeededInner and assigns it to the FileNeeded field.
   760  func (o *ServerInfo) SetFileNeeded(v []FileNeededInner) {
   761  	o.FileNeeded = v
   762  }
   763  
   764  func (o ServerInfo) MarshalJSON() ([]byte, error) {
   765  	toSerialize := map[string]interface{}{}
   766  	if o.PacketVersion != nil {
   767  		toSerialize["PacketVersion"] = o.PacketVersion
   768  	}
   769  	if o.Application != nil {
   770  		toSerialize["Application"] = o.Application
   771  	}
   772  	if o.Version != nil {
   773  		toSerialize["Version"] = o.Version
   774  	}
   775  	if o.SubVersion != nil {
   776  		toSerialize["SubVersion"] = o.SubVersion
   777  	}
   778  	if o.NumberOfPlayer != nil {
   779  		toSerialize["NumberOfPlayer"] = o.NumberOfPlayer
   780  	}
   781  	if o.MaxPlayers != nil {
   782  		toSerialize["MaxPlayers"] = o.MaxPlayers
   783  	}
   784  	if o.GameType != nil {
   785  		toSerialize["GameType"] = o.GameType
   786  	}
   787  	if o.ModifiedGame != nil {
   788  		toSerialize["ModifiedGame"] = o.ModifiedGame
   789  	}
   790  	if o.CheatsEnabled != nil {
   791  		toSerialize["CheatsEnabled"] = o.CheatsEnabled
   792  	}
   793  	if o.KartVars != nil {
   794  		toSerialize["KartVars"] = o.KartVars
   795  	}
   796  	if o.FileNeededNum != nil {
   797  		toSerialize["FileNeededNum"] = o.FileNeededNum
   798  	}
   799  	if o.Time != nil {
   800  		toSerialize["Time"] = o.Time
   801  	}
   802  	if o.LevelTime != nil {
   803  		toSerialize["LevelTime"] = o.LevelTime
   804  	}
   805  	if o.ServerNameRaw != nil {
   806  		toSerialize["ServerNameRaw"] = o.ServerNameRaw
   807  	}
   808  	if o.ServerName != nil {
   809  		toSerialize["ServerName"] = o.ServerName
   810  	}
   811  	if o.MapName != nil {
   812  		toSerialize["MapName"] = o.MapName
   813  	}
   814  	if o.MapTitle != nil {
   815  		toSerialize["MapTitle"] = o.MapTitle
   816  	}
   817  	if o.MapMD5 != nil {
   818  		toSerialize["MapMD5"] = o.MapMD5
   819  	}
   820  	if o.ActNum != nil {
   821  		toSerialize["ActNum"] = o.ActNum
   822  	}
   823  	if o.IsZone != nil {
   824  		toSerialize["IsZone"] = o.IsZone
   825  	}
   826  	if o.HttpSource != nil {
   827  		toSerialize["HttpSource"] = o.HttpSource
   828  	}
   829  	if o.FileNeeded != nil {
   830  		toSerialize["FileNeeded"] = o.FileNeeded
   831  	}
   832  	return json.Marshal(toSerialize)
   833  }
   834  
   835  type NullableServerInfo struct {
   836  	value *ServerInfo
   837  	isSet bool
   838  }
   839  
   840  func (v NullableServerInfo) Get() *ServerInfo {
   841  	return v.value
   842  }
   843  
   844  func (v *NullableServerInfo) Set(val *ServerInfo) {
   845  	v.value = val
   846  	v.isSet = true
   847  }
   848  
   849  func (v NullableServerInfo) IsSet() bool {
   850  	return v.isSet
   851  }
   852  
   853  func (v *NullableServerInfo) Unset() {
   854  	v.value = nil
   855  	v.isSet = false
   856  }
   857  
   858  func NewNullableServerInfo(val *ServerInfo) *NullableServerInfo {
   859  	return &NullableServerInfo{value: val, isSet: true}
   860  }
   861  
   862  func (v NullableServerInfo) MarshalJSON() ([]byte, error) {
   863  	return json.Marshal(v.value)
   864  }
   865  
   866  func (v *NullableServerInfo) UnmarshalJSON(src []byte) error {
   867  	v.isSet = true
   868  	return json.Unmarshal(src, &v.value)
   869  }
   870  
   871  
   872  

View as plain text