swaggy_jenkins 0.0.1 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/Gemfile +3 -1
- data/Gemfile.lock +51 -50
- data/README.md +25 -33
- data/Rakefile +2 -0
- data/bin/bundle +114 -0
- data/bin/byebug +29 -0
- data/bin/coderay +29 -0
- data/bin/htmldiff +29 -0
- data/bin/ldiff +29 -0
- data/bin/pry +29 -0
- data/bin/rake +29 -0
- data/bin/rspec +29 -0
- data/bin/rubocop +29 -0
- data/bin/ruby-parse +29 -0
- data/bin/ruby-rewrite +29 -0
- data/docs/AllView.md +17 -5
- data/docs/BaseApi.md +75 -0
- data/docs/BlueOceanApi.md +1347 -631
- data/docs/BranchImpl.md +37 -15
- data/docs/BranchImpllinks.md +21 -7
- data/docs/BranchImplpermissions.md +21 -7
- data/docs/CauseAction.md +15 -4
- data/docs/CauseUserIdCause.md +19 -6
- data/docs/ClassesByClass.md +15 -4
- data/docs/ClockDifference.md +15 -4
- data/docs/ComputerSet.md +21 -7
- data/docs/DefaultCrumbIssuer.md +17 -5
- data/docs/DiskSpaceMonitorDescriptorDiskSpace.md +19 -6
- data/docs/EmptyChangeLogSet.md +15 -4
- data/docs/ExtensionClassContainerImpl1.md +17 -5
- data/docs/ExtensionClassContainerImpl1links.md +15 -4
- data/docs/ExtensionClassContainerImpl1map.md +17 -5
- data/docs/ExtensionClassImpl.md +17 -5
- data/docs/ExtensionClassImpllinks.md +15 -4
- data/docs/FavoriteImpl.md +17 -5
- data/docs/FavoriteImpllinks.md +15 -4
- data/docs/FreeStyleBuild.md +47 -20
- data/docs/FreeStyleProject.md +65 -29
- data/docs/FreeStyleProjectactions.md +13 -3
- data/docs/FreeStyleProjecthealthReport.md +21 -7
- data/docs/GenericResource.md +23 -8
- data/docs/GithubContent.md +27 -10
- data/docs/GithubFile.md +15 -4
- data/docs/GithubOrganization.md +19 -6
- data/docs/GithubOrganizationlinks.md +17 -5
- data/docs/GithubRepositories.md +23 -8
- data/docs/GithubRepositorieslinks.md +15 -4
- data/docs/GithubRepository.md +27 -10
- data/docs/GithubRepositorylinks.md +15 -4
- data/docs/GithubRepositorypermissions.md +19 -6
- data/docs/GithubRespositoryContainer.md +17 -5
- data/docs/GithubRespositoryContainerlinks.md +15 -4
- data/docs/GithubScm.md +21 -7
- data/docs/GithubScmlinks.md +15 -4
- data/docs/Hudson.md +41 -17
- data/docs/HudsonMasterComputer.md +43 -18
- data/docs/HudsonMasterComputerexecutors.md +23 -8
- data/docs/HudsonMasterComputermonitorData.md +25 -9
- data/docs/HudsonassignedLabels.md +13 -3
- data/docs/InputStepImpl.md +25 -9
- data/docs/InputStepImpllinks.md +15 -4
- data/docs/Label1.md +13 -3
- data/docs/Link.md +15 -4
- data/docs/ListView.md +21 -7
- data/docs/MultibranchPipeline.md +39 -16
- data/docs/NullSCM.md +13 -3
- data/docs/Organisation.md +15 -4
- data/docs/Pipeline.md +27 -10
- data/docs/PipelineActivity.md +41 -17
- data/docs/PipelineActivityartifacts.md +19 -6
- data/docs/PipelineBranchesitem.md +29 -11
- data/docs/PipelineBranchesitemlatestRun.md +39 -16
- data/docs/PipelineBranchesitempullRequest.md +23 -8
- data/docs/PipelineBranchesitempullRequestlinks.md +15 -4
- data/docs/PipelineFolderImpl.md +25 -9
- data/docs/PipelineImpl.md +29 -11
- data/docs/PipelineImpllinks.md +21 -7
- data/docs/PipelineRun.md +41 -17
- data/docs/PipelineRunImpl.md +41 -17
- data/docs/PipelineRunImpllinks.md +23 -8
- data/docs/PipelineRunNode.md +27 -10
- data/docs/PipelineRunNodeedges.md +15 -4
- data/docs/PipelineRunartifacts.md +19 -6
- data/docs/PipelineStepImpl.md +29 -11
- data/docs/PipelineStepImpllinks.md +17 -5
- data/docs/PipelinelatestRun.md +41 -17
- data/docs/PipelinelatestRunartifacts.md +19 -6
- data/docs/Queue.md +15 -4
- data/docs/QueueBlockedItem.md +35 -14
- data/docs/QueueItemImpl.md +21 -7
- data/docs/QueueLeftItem.md +37 -15
- data/docs/RemoteAccessApi.md +666 -350
- data/docs/ResponseTimeMonitorData.md +17 -5
- data/docs/StringParameterDefinition.md +21 -7
- data/docs/StringParameterValue.md +17 -5
- data/docs/SwapSpaceMonitorMemoryUsage2.md +21 -7
- data/docs/UnlabeledLoadStatistics.md +13 -3
- data/docs/User.md +21 -7
- data/git_push.sh +12 -10
- data/lib/swaggy_jenkins/api/base_api.rb +77 -0
- data/lib/swaggy_jenkins/api/blue_ocean_api.rb +1048 -643
- data/lib/swaggy_jenkins/api/remote_access_api.rb +506 -361
- data/lib/swaggy_jenkins/api_client.rb +95 -94
- data/lib/swaggy_jenkins/api_error.rb +22 -3
- data/lib/swaggy_jenkins/configuration.rb +91 -15
- data/lib/swaggy_jenkins/models/all_view.rb +59 -29
- data/lib/swaggy_jenkins/models/branch_impl.rb +76 -46
- data/lib/swaggy_jenkins/models/branch_impllinks.rb +62 -32
- data/lib/swaggy_jenkins/models/branch_implpermissions.rb +65 -35
- data/lib/swaggy_jenkins/models/cause_action.rb +58 -28
- data/lib/swaggy_jenkins/models/cause_user_id_cause.rb +63 -33
- data/lib/swaggy_jenkins/models/classes_by_class.rb +58 -28
- data/lib/swaggy_jenkins/models/clock_difference.rb +58 -28
- data/lib/swaggy_jenkins/models/computer_set.rb +64 -34
- data/lib/swaggy_jenkins/models/default_crumb_issuer.rb +60 -30
- data/lib/swaggy_jenkins/models/disk_space_monitor_descriptor_disk_space.rb +60 -30
- data/lib/swaggy_jenkins/models/empty_change_log_set.rb +58 -28
- data/lib/swaggy_jenkins/models/extension_class_container_impl1.rb +59 -29
- data/lib/swaggy_jenkins/models/extension_class_container_impl1links.rb +59 -29
- data/lib/swaggy_jenkins/models/extension_class_container_impl1map.rb +61 -31
- data/lib/swaggy_jenkins/models/extension_class_impl.rb +59 -29
- data/lib/swaggy_jenkins/models/extension_class_impllinks.rb +59 -29
- data/lib/swaggy_jenkins/models/favorite_impl.rb +59 -29
- data/lib/swaggy_jenkins/models/favorite_impllinks.rb +59 -29
- data/lib/swaggy_jenkins/models/free_style_build.rb +83 -53
- data/lib/swaggy_jenkins/models/free_style_project.rb +105 -75
- data/lib/swaggy_jenkins/models/free_style_projectactions.rb +57 -27
- data/lib/swaggy_jenkins/models/free_style_projecthealth_report.rb +63 -33
- data/lib/swaggy_jenkins/models/generic_resource.rb +65 -35
- data/lib/swaggy_jenkins/models/github_content.rb +65 -35
- data/lib/swaggy_jenkins/models/github_file.rb +58 -28
- data/lib/swaggy_jenkins/models/github_organization.rb +62 -32
- data/lib/swaggy_jenkins/models/github_organizationlinks.rb +60 -30
- data/lib/swaggy_jenkins/models/github_repositories.rb +65 -35
- data/lib/swaggy_jenkins/models/github_repositorieslinks.rb +59 -29
- data/lib/swaggy_jenkins/models/github_repository.rb +67 -37
- data/lib/swaggy_jenkins/models/github_repositorylinks.rb +59 -29
- data/lib/swaggy_jenkins/models/github_repositorypermissions.rb +63 -33
- data/lib/swaggy_jenkins/models/github_respository_container.rb +59 -29
- data/lib/swaggy_jenkins/models/github_respository_containerlinks.rb +59 -29
- data/lib/swaggy_jenkins/models/github_scm.rb +62 -32
- data/lib/swaggy_jenkins/models/github_scmlinks.rb +59 -29
- data/lib/swaggy_jenkins/models/hudson.rb +84 -54
- data/lib/swaggy_jenkins/models/hudson_master_computer.rb +89 -59
- data/lib/swaggy_jenkins/models/hudson_master_computerexecutors.rb +66 -36
- data/lib/swaggy_jenkins/models/hudson_master_computermonitor_data.rb +69 -39
- data/lib/swaggy_jenkins/models/hudsonassigned_labels.rb +57 -27
- data/lib/swaggy_jenkins/models/input_step_impl.rb +63 -33
- data/lib/swaggy_jenkins/models/input_step_impllinks.rb +59 -29
- data/lib/swaggy_jenkins/models/label1.rb +57 -27
- data/lib/swaggy_jenkins/models/link.rb +58 -28
- data/lib/swaggy_jenkins/models/list_view.rb +61 -31
- data/lib/swaggy_jenkins/models/multibranch_pipeline.rb +81 -51
- data/lib/swaggy_jenkins/models/null_scm.rb +57 -27
- data/lib/swaggy_jenkins/models/organisation.rb +58 -28
- data/lib/swaggy_jenkins/models/pipeline.rb +69 -39
- data/lib/swaggy_jenkins/models/pipeline_activity.rb +78 -48
- data/lib/swaggy_jenkins/models/pipeline_activityartifacts.rb +60 -30
- data/lib/swaggy_jenkins/models/pipeline_branchesitem.rb +71 -41
- data/lib/swaggy_jenkins/models/pipeline_branchesitemlatest_run.rb +77 -47
- data/lib/swaggy_jenkins/models/pipeline_branchesitempull_request.rb +62 -32
- data/lib/swaggy_jenkins/models/pipeline_branchesitempull_requestlinks.rb +59 -29
- data/lib/swaggy_jenkins/models/pipeline_folder_impl.rb +67 -37
- data/lib/swaggy_jenkins/models/pipeline_impl.rb +70 -40
- data/lib/swaggy_jenkins/models/pipeline_impllinks.rb +62 -32
- data/lib/swaggy_jenkins/models/pipeline_run.rb +78 -48
- data/lib/swaggy_jenkins/models/pipeline_run_impl.rb +78 -48
- data/lib/swaggy_jenkins/models/pipeline_run_impllinks.rb +63 -33
- data/lib/swaggy_jenkins/models/pipeline_run_node.rb +67 -37
- data/lib/swaggy_jenkins/models/pipeline_run_nodeedges.rb +58 -28
- data/lib/swaggy_jenkins/models/pipeline_runartifacts.rb +60 -30
- data/lib/swaggy_jenkins/models/pipeline_step_impl.rb +68 -38
- data/lib/swaggy_jenkins/models/pipeline_step_impllinks.rb +60 -30
- data/lib/swaggy_jenkins/models/pipelinelatest_run.rb +78 -48
- data/lib/swaggy_jenkins/models/pipelinelatest_runartifacts.rb +60 -30
- data/lib/swaggy_jenkins/models/queue.rb +58 -28
- data/lib/swaggy_jenkins/models/queue_blocked_item.rb +73 -43
- data/lib/swaggy_jenkins/models/queue_item_impl.rb +63 -33
- data/lib/swaggy_jenkins/models/queue_left_item.rb +74 -44
- data/lib/swaggy_jenkins/models/response_time_monitor_data.rb +59 -29
- data/lib/swaggy_jenkins/models/string_parameter_definition.rb +62 -32
- data/lib/swaggy_jenkins/models/string_parameter_value.rb +59 -29
- data/lib/swaggy_jenkins/models/swap_space_monitor_memory_usage2.rb +65 -35
- data/lib/swaggy_jenkins/models/unlabeled_load_statistics.rb +57 -27
- data/lib/swaggy_jenkins/models/user.rb +62 -32
- data/lib/swaggy_jenkins/version.rb +4 -4
- data/lib/swaggy_jenkins.rb +4 -16
- data/spec/api/base_api_spec.rb +45 -0
- data/spec/api/blue_ocean_api_spec.rb +76 -88
- data/spec/api/remote_access_api_spec.rb +28 -59
- data/spec/api_client_spec.rb +40 -40
- data/spec/configuration_spec.rb +11 -11
- data/spec/models/all_view_spec.rb +10 -18
- data/spec/models/branch_impl_spec.rb +20 -28
- data/spec/models/branch_impllinks_spec.rb +12 -20
- data/spec/models/branch_implpermissions_spec.rb +12 -20
- data/spec/models/cause_action_spec.rb +9 -17
- data/spec/models/cause_user_id_cause_spec.rb +11 -19
- data/spec/models/classes_by_class_spec.rb +9 -17
- data/spec/models/clock_difference_spec.rb +9 -17
- data/spec/models/computer_set_spec.rb +12 -20
- data/spec/models/default_crumb_issuer_spec.rb +10 -18
- data/spec/models/disk_space_monitor_descriptor_disk_space_spec.rb +11 -19
- data/spec/models/empty_change_log_set_spec.rb +9 -17
- data/spec/models/extension_class_container_impl1_spec.rb +10 -18
- data/spec/models/extension_class_container_impl1links_spec.rb +9 -17
- data/spec/models/extension_class_container_impl1map_spec.rb +10 -18
- data/spec/models/extension_class_impl_spec.rb +10 -18
- data/spec/models/extension_class_impllinks_spec.rb +9 -17
- data/spec/models/favorite_impl_spec.rb +10 -18
- data/spec/models/favorite_impllinks_spec.rb +9 -17
- data/spec/models/free_style_build_spec.rb +25 -33
- data/spec/models/free_style_project_spec.rb +34 -42
- data/spec/models/free_style_projectactions_spec.rb +8 -16
- data/spec/models/free_style_projecthealth_report_spec.rb +12 -20
- data/spec/models/generic_resource_spec.rb +13 -21
- data/spec/models/github_content_spec.rb +15 -23
- data/spec/models/github_file_spec.rb +9 -17
- data/spec/models/github_organization_spec.rb +11 -19
- data/spec/models/github_organizationlinks_spec.rb +10 -18
- data/spec/models/github_repositories_spec.rb +13 -21
- data/spec/models/github_repositorieslinks_spec.rb +9 -17
- data/spec/models/github_repository_spec.rb +15 -23
- data/spec/models/github_repositorylinks_spec.rb +9 -17
- data/spec/models/github_repositorypermissions_spec.rb +11 -19
- data/spec/models/github_respository_container_spec.rb +10 -18
- data/spec/models/github_respository_containerlinks_spec.rb +9 -17
- data/spec/models/github_scm_spec.rb +12 -20
- data/spec/models/github_scmlinks_spec.rb +9 -17
- data/spec/models/hudson_master_computer_spec.rb +23 -31
- data/spec/models/hudson_master_computerexecutors_spec.rb +13 -21
- data/spec/models/hudson_master_computermonitor_data_spec.rb +14 -22
- data/spec/models/hudson_spec.rb +22 -30
- data/spec/models/hudsonassigned_labels_spec.rb +8 -16
- data/spec/models/input_step_impl_spec.rb +14 -22
- data/spec/models/input_step_impllinks_spec.rb +9 -17
- data/spec/models/label1_spec.rb +8 -16
- data/spec/models/link_spec.rb +9 -17
- data/spec/models/list_view_spec.rb +12 -20
- data/spec/models/multibranch_pipeline_spec.rb +21 -29
- data/spec/models/null_scm_spec.rb +8 -16
- data/spec/models/organisation_spec.rb +9 -17
- data/spec/models/pipeline_activity_spec.rb +22 -30
- data/spec/models/pipeline_activityartifacts_spec.rb +11 -19
- data/spec/models/pipeline_branchesitem_spec.rb +16 -24
- data/spec/models/pipeline_branchesitemlatest_run_spec.rb +21 -29
- data/spec/models/pipeline_branchesitempull_request_spec.rb +13 -21
- data/spec/models/pipeline_branchesitempull_requestlinks_spec.rb +9 -17
- data/spec/models/pipeline_folder_impl_spec.rb +14 -22
- data/spec/models/pipeline_impl_spec.rb +16 -24
- data/spec/models/pipeline_impllinks_spec.rb +12 -20
- data/spec/models/pipeline_run_impl_spec.rb +22 -30
- data/spec/models/pipeline_run_impllinks_spec.rb +13 -21
- data/spec/models/pipeline_run_node_spec.rb +15 -23
- data/spec/models/pipeline_run_nodeedges_spec.rb +9 -17
- data/spec/models/pipeline_run_spec.rb +22 -30
- data/spec/models/pipeline_runartifacts_spec.rb +11 -19
- data/spec/models/pipeline_spec.rb +15 -23
- data/spec/models/pipeline_step_impl_spec.rb +16 -24
- data/spec/models/pipeline_step_impllinks_spec.rb +10 -18
- data/spec/models/pipelinelatest_run_spec.rb +22 -30
- data/spec/models/pipelinelatest_runartifacts_spec.rb +11 -19
- data/spec/models/queue_blocked_item_spec.rb +19 -27
- data/spec/models/queue_item_impl_spec.rb +12 -20
- data/spec/models/queue_left_item_spec.rb +20 -28
- data/spec/models/queue_spec.rb +9 -17
- data/spec/models/response_time_monitor_data_spec.rb +10 -18
- data/spec/models/string_parameter_definition_spec.rb +12 -20
- data/spec/models/string_parameter_value_spec.rb +10 -18
- data/spec/models/swap_space_monitor_memory_usage2_spec.rb +12 -20
- data/spec/models/unlabeled_load_statistics_spec.rb +8 -16
- data/spec/models/user_spec.rb +12 -20
- data/spec/spec_helper.rb +3 -3
- data/swaggy_jenkins.gemspec +6 -13
- metadata +97 -275
- data/docs/Body.md +0 -8
- data/docs/Organisations.md +0 -7
- data/docs/PipelineActivities.md +0 -7
- data/docs/PipelineBranches.md +0 -7
- data/docs/PipelineQueue.md +0 -7
- data/docs/PipelineRunNodeSteps.md +0 -7
- data/docs/PipelineRunNodes.md +0 -7
- data/docs/PipelineRunSteps.md +0 -7
- data/docs/PipelineRuns.md +0 -7
- data/docs/Pipelines.md +0 -7
- data/docs/ScmOrganisations.md +0 -7
- data/docs/UserFavorites.md +0 -7
- data/docs/Users.md +0 -7
- data/lib/swaggy_jenkins/models/body.rb +0 -193
- data/lib/swaggy_jenkins/models/organisations.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_activities.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_branches.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_queue.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_run_node_steps.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_run_nodes.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_run_steps.rb +0 -179
- data/lib/swaggy_jenkins/models/pipeline_runs.rb +0 -179
- data/lib/swaggy_jenkins/models/pipelines.rb +0 -179
- data/lib/swaggy_jenkins/models/scm_organisations.rb +0 -179
- data/lib/swaggy_jenkins/models/user_favorites.rb +0 -179
- data/lib/swaggy_jenkins/models/users.rb +0 -179
- data/spec/models/body_spec.rb +0 -42
- data/spec/models/organisations_spec.rb +0 -36
- data/spec/models/pipeline_activities_spec.rb +0 -36
- data/spec/models/pipeline_branches_spec.rb +0 -36
- data/spec/models/pipeline_queue_spec.rb +0 -36
- data/spec/models/pipeline_run_node_steps_spec.rb +0 -36
- data/spec/models/pipeline_run_nodes_spec.rb +0 -36
- data/spec/models/pipeline_run_steps_spec.rb +0 -36
- data/spec/models/pipeline_runs_spec.rb +0 -36
- data/spec/models/pipelines_spec.rb +0 -36
- data/spec/models/scm_organisations_spec.rb +0 -36
- data/spec/models/user_favorites_spec.rb +0 -36
- data/spec/models/users_spec.rb +0 -36
@@ -3,17 +3,17 @@
|
|
3
3
|
|
4
4
|
#Jenkins API clients generated from Swagger / Open API specification
|
5
5
|
|
6
|
-
OpenAPI
|
6
|
+
The version of the OpenAPI document: 1.3.0
|
7
7
|
Contact: blah@cliffano.com
|
8
|
-
Generated by: https://
|
9
|
-
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.4.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
|
+
require 'time'
|
14
15
|
|
15
16
|
module SwaggyJenkinsClient
|
16
|
-
|
17
17
|
class Hudson
|
18
18
|
attr_accessor :_class
|
19
19
|
|
@@ -45,7 +45,6 @@ module SwaggyJenkinsClient
|
|
45
45
|
|
46
46
|
attr_accessor :views
|
47
47
|
|
48
|
-
|
49
48
|
# Attribute mapping from ruby-style variable name to JSON key.
|
50
49
|
def self.attribute_map
|
51
50
|
{
|
@@ -67,8 +66,13 @@ module SwaggyJenkinsClient
|
|
67
66
|
}
|
68
67
|
end
|
69
68
|
|
69
|
+
# Returns all the JSON keys this model knows about
|
70
|
+
def self.acceptable_attributes
|
71
|
+
attribute_map.values
|
72
|
+
end
|
73
|
+
|
70
74
|
# Attribute type mapping.
|
71
|
-
def self.
|
75
|
+
def self.openapi_types
|
72
76
|
{
|
73
77
|
:'_class' => :'String',
|
74
78
|
:'assigned_labels' => :'Array<HudsonassignedLabels>',
|
@@ -79,102 +83,114 @@ module SwaggyJenkinsClient
|
|
79
83
|
:'description' => :'String',
|
80
84
|
:'jobs' => :'Array<FreeStyleProject>',
|
81
85
|
:'primary_view' => :'AllView',
|
82
|
-
:'quieting_down' => :'
|
86
|
+
:'quieting_down' => :'Boolean',
|
83
87
|
:'slave_agent_port' => :'Integer',
|
84
88
|
:'unlabeled_load' => :'UnlabeledLoadStatistics',
|
85
|
-
:'use_crumbs' => :'
|
86
|
-
:'use_security' => :'
|
89
|
+
:'use_crumbs' => :'Boolean',
|
90
|
+
:'use_security' => :'Boolean',
|
87
91
|
:'views' => :'Array<AllView>'
|
88
92
|
}
|
89
93
|
end
|
90
94
|
|
95
|
+
# List of attributes with nullable: true
|
96
|
+
def self.openapi_nullable
|
97
|
+
Set.new([
|
98
|
+
])
|
99
|
+
end
|
100
|
+
|
91
101
|
# Initializes the object
|
92
102
|
# @param [Hash] attributes Model attributes in the form of hash
|
93
103
|
def initialize(attributes = {})
|
94
|
-
|
104
|
+
if (!attributes.is_a?(Hash))
|
105
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggyJenkinsClient::Hudson` initialize method"
|
106
|
+
end
|
95
107
|
|
96
|
-
# convert string to symbol for hash key
|
97
|
-
attributes = attributes.each_with_object({}){|(k,v), h|
|
108
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
109
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
110
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
111
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggyJenkinsClient::Hudson`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
112
|
+
end
|
113
|
+
h[k.to_sym] = v
|
114
|
+
}
|
98
115
|
|
99
|
-
if attributes.
|
116
|
+
if attributes.key?(:'_class')
|
100
117
|
self._class = attributes[:'_class']
|
101
118
|
end
|
102
119
|
|
103
|
-
if attributes.
|
104
|
-
if (value = attributes[:'
|
120
|
+
if attributes.key?(:'assigned_labels')
|
121
|
+
if (value = attributes[:'assigned_labels']).is_a?(Array)
|
105
122
|
self.assigned_labels = value
|
106
123
|
end
|
107
124
|
end
|
108
125
|
|
109
|
-
if attributes.
|
126
|
+
if attributes.key?(:'mode')
|
110
127
|
self.mode = attributes[:'mode']
|
111
128
|
end
|
112
129
|
|
113
|
-
if attributes.
|
114
|
-
self.node_description = attributes[:'
|
130
|
+
if attributes.key?(:'node_description')
|
131
|
+
self.node_description = attributes[:'node_description']
|
115
132
|
end
|
116
133
|
|
117
|
-
if attributes.
|
118
|
-
self.node_name = attributes[:'
|
134
|
+
if attributes.key?(:'node_name')
|
135
|
+
self.node_name = attributes[:'node_name']
|
119
136
|
end
|
120
137
|
|
121
|
-
if attributes.
|
122
|
-
self.num_executors = attributes[:'
|
138
|
+
if attributes.key?(:'num_executors')
|
139
|
+
self.num_executors = attributes[:'num_executors']
|
123
140
|
end
|
124
141
|
|
125
|
-
if attributes.
|
142
|
+
if attributes.key?(:'description')
|
126
143
|
self.description = attributes[:'description']
|
127
144
|
end
|
128
145
|
|
129
|
-
if attributes.
|
146
|
+
if attributes.key?(:'jobs')
|
130
147
|
if (value = attributes[:'jobs']).is_a?(Array)
|
131
148
|
self.jobs = value
|
132
149
|
end
|
133
150
|
end
|
134
151
|
|
135
|
-
if attributes.
|
136
|
-
self.primary_view = attributes[:'
|
152
|
+
if attributes.key?(:'primary_view')
|
153
|
+
self.primary_view = attributes[:'primary_view']
|
137
154
|
end
|
138
155
|
|
139
|
-
if attributes.
|
140
|
-
self.quieting_down = attributes[:'
|
156
|
+
if attributes.key?(:'quieting_down')
|
157
|
+
self.quieting_down = attributes[:'quieting_down']
|
141
158
|
end
|
142
159
|
|
143
|
-
if attributes.
|
144
|
-
self.slave_agent_port = attributes[:'
|
160
|
+
if attributes.key?(:'slave_agent_port')
|
161
|
+
self.slave_agent_port = attributes[:'slave_agent_port']
|
145
162
|
end
|
146
163
|
|
147
|
-
if attributes.
|
148
|
-
self.unlabeled_load = attributes[:'
|
164
|
+
if attributes.key?(:'unlabeled_load')
|
165
|
+
self.unlabeled_load = attributes[:'unlabeled_load']
|
149
166
|
end
|
150
167
|
|
151
|
-
if attributes.
|
152
|
-
self.use_crumbs = attributes[:'
|
168
|
+
if attributes.key?(:'use_crumbs')
|
169
|
+
self.use_crumbs = attributes[:'use_crumbs']
|
153
170
|
end
|
154
171
|
|
155
|
-
if attributes.
|
156
|
-
self.use_security = attributes[:'
|
172
|
+
if attributes.key?(:'use_security')
|
173
|
+
self.use_security = attributes[:'use_security']
|
157
174
|
end
|
158
175
|
|
159
|
-
if attributes.
|
176
|
+
if attributes.key?(:'views')
|
160
177
|
if (value = attributes[:'views']).is_a?(Array)
|
161
178
|
self.views = value
|
162
179
|
end
|
163
180
|
end
|
164
|
-
|
165
181
|
end
|
166
182
|
|
167
183
|
# Show invalid properties with the reasons. Usually used together with valid?
|
168
|
-
# @return Array for valid
|
184
|
+
# @return Array for valid properties with the reasons
|
169
185
|
def list_invalid_properties
|
170
186
|
invalid_properties = Array.new
|
171
|
-
|
187
|
+
invalid_properties
|
172
188
|
end
|
173
189
|
|
174
190
|
# Check to see if the all the properties in the model are valid
|
175
191
|
# @return true if the model is valid
|
176
192
|
def valid?
|
177
|
-
|
193
|
+
true
|
178
194
|
end
|
179
195
|
|
180
196
|
# Checks equality by comparing each attribute.
|
@@ -206,26 +222,35 @@ module SwaggyJenkinsClient
|
|
206
222
|
end
|
207
223
|
|
208
224
|
# Calculates hash code according to all attributes.
|
209
|
-
# @return [
|
225
|
+
# @return [Integer] Hash code
|
210
226
|
def hash
|
211
227
|
[_class, assigned_labels, mode, node_description, node_name, num_executors, description, jobs, primary_view, quieting_down, slave_agent_port, unlabeled_load, use_crumbs, use_security, views].hash
|
212
228
|
end
|
213
229
|
|
230
|
+
# Builds the object from hash
|
231
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
232
|
+
# @return [Object] Returns the model itself
|
233
|
+
def self.build_from_hash(attributes)
|
234
|
+
new.build_from_hash(attributes)
|
235
|
+
end
|
236
|
+
|
214
237
|
# Builds the object from hash
|
215
238
|
# @param [Hash] attributes Model attributes in the form of hash
|
216
239
|
# @return [Object] Returns the model itself
|
217
240
|
def build_from_hash(attributes)
|
218
241
|
return nil unless attributes.is_a?(Hash)
|
219
|
-
self.class.
|
220
|
-
if
|
221
|
-
#
|
242
|
+
self.class.openapi_types.each_pair do |key, type|
|
243
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
244
|
+
self.send("#{key}=", nil)
|
245
|
+
elsif type =~ /\AArray<(.*)>/i
|
246
|
+
# check to ensure the input is an array given that the attribute
|
222
247
|
# is documented as an array but the input is not
|
223
248
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
224
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
249
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
225
250
|
end
|
226
251
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
227
252
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
228
|
-
end
|
253
|
+
end
|
229
254
|
end
|
230
255
|
|
231
256
|
self
|
@@ -237,8 +262,8 @@ module SwaggyJenkinsClient
|
|
237
262
|
# @return [Object] Deserialized data
|
238
263
|
def _deserialize(type, value)
|
239
264
|
case type.to_sym
|
240
|
-
when :
|
241
|
-
|
265
|
+
when :Time
|
266
|
+
Time.parse(value)
|
242
267
|
when :Date
|
243
268
|
Date.parse(value)
|
244
269
|
when :String
|
@@ -247,7 +272,7 @@ module SwaggyJenkinsClient
|
|
247
272
|
value.to_i
|
248
273
|
when :Float
|
249
274
|
value.to_f
|
250
|
-
when :
|
275
|
+
when :Boolean
|
251
276
|
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
252
277
|
true
|
253
278
|
else
|
@@ -268,8 +293,9 @@ module SwaggyJenkinsClient
|
|
268
293
|
end
|
269
294
|
end
|
270
295
|
else # model
|
271
|
-
|
272
|
-
|
296
|
+
# models (e.g. Pet) or oneOf
|
297
|
+
klass = SwaggyJenkinsClient.const_get(type)
|
298
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
273
299
|
end
|
274
300
|
end
|
275
301
|
|
@@ -291,7 +317,11 @@ module SwaggyJenkinsClient
|
|
291
317
|
hash = {}
|
292
318
|
self.class.attribute_map.each_pair do |attr, param|
|
293
319
|
value = self.send(attr)
|
294
|
-
|
320
|
+
if value.nil?
|
321
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
322
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
323
|
+
end
|
324
|
+
|
295
325
|
hash[param] = _to_hash(value)
|
296
326
|
end
|
297
327
|
hash
|
@@ -303,7 +333,7 @@ module SwaggyJenkinsClient
|
|
303
333
|
# @return [Hash] Returns the value in the form of hash
|
304
334
|
def _to_hash(value)
|
305
335
|
if value.is_a?(Array)
|
306
|
-
value.compact.map{ |v| _to_hash(v) }
|
336
|
+
value.compact.map { |v| _to_hash(v) }
|
307
337
|
elsif value.is_a?(Hash)
|
308
338
|
{}.tap do |hash|
|
309
339
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -3,17 +3,17 @@
|
|
3
3
|
|
4
4
|
#Jenkins API clients generated from Swagger / Open API specification
|
5
5
|
|
6
|
-
OpenAPI
|
6
|
+
The version of the OpenAPI document: 1.3.0
|
7
7
|
Contact: blah@cliffano.com
|
8
|
-
Generated by: https://
|
9
|
-
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.4.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
|
+
require 'time'
|
14
15
|
|
15
16
|
module SwaggyJenkinsClient
|
16
|
-
|
17
17
|
class HudsonMasterComputer
|
18
18
|
attr_accessor :_class
|
19
19
|
|
@@ -47,7 +47,6 @@ module SwaggyJenkinsClient
|
|
47
47
|
|
48
48
|
attr_accessor :temporarily_offline
|
49
49
|
|
50
|
-
|
51
50
|
# Attribute mapping from ruby-style variable name to JSON key.
|
52
51
|
def self.attribute_map
|
53
52
|
{
|
@@ -70,115 +69,132 @@ module SwaggyJenkinsClient
|
|
70
69
|
}
|
71
70
|
end
|
72
71
|
|
72
|
+
# Returns all the JSON keys this model knows about
|
73
|
+
def self.acceptable_attributes
|
74
|
+
attribute_map.values
|
75
|
+
end
|
76
|
+
|
73
77
|
# Attribute type mapping.
|
74
|
-
def self.
|
78
|
+
def self.openapi_types
|
75
79
|
{
|
76
80
|
:'_class' => :'String',
|
77
81
|
:'display_name' => :'String',
|
78
82
|
:'executors' => :'Array<HudsonMasterComputerexecutors>',
|
79
83
|
:'icon' => :'String',
|
80
84
|
:'icon_class_name' => :'String',
|
81
|
-
:'idle' => :'
|
82
|
-
:'jnlp_agent' => :'
|
83
|
-
:'launch_supported' => :'
|
85
|
+
:'idle' => :'Boolean',
|
86
|
+
:'jnlp_agent' => :'Boolean',
|
87
|
+
:'launch_supported' => :'Boolean',
|
84
88
|
:'load_statistics' => :'Label1',
|
85
|
-
:'manual_launch_allowed' => :'
|
89
|
+
:'manual_launch_allowed' => :'Boolean',
|
86
90
|
:'monitor_data' => :'HudsonMasterComputermonitorData',
|
87
91
|
:'num_executors' => :'Integer',
|
88
|
-
:'offline' => :'
|
92
|
+
:'offline' => :'Boolean',
|
89
93
|
:'offline_cause' => :'String',
|
90
94
|
:'offline_cause_reason' => :'String',
|
91
|
-
:'temporarily_offline' => :'
|
95
|
+
:'temporarily_offline' => :'Boolean'
|
92
96
|
}
|
93
97
|
end
|
94
98
|
|
99
|
+
# List of attributes with nullable: true
|
100
|
+
def self.openapi_nullable
|
101
|
+
Set.new([
|
102
|
+
])
|
103
|
+
end
|
104
|
+
|
95
105
|
# Initializes the object
|
96
106
|
# @param [Hash] attributes Model attributes in the form of hash
|
97
107
|
def initialize(attributes = {})
|
98
|
-
|
108
|
+
if (!attributes.is_a?(Hash))
|
109
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggyJenkinsClient::HudsonMasterComputer` initialize method"
|
110
|
+
end
|
99
111
|
|
100
|
-
# convert string to symbol for hash key
|
101
|
-
attributes = attributes.each_with_object({}){|(k,v), h|
|
112
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
113
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
114
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
115
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggyJenkinsClient::HudsonMasterComputer`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
116
|
+
end
|
117
|
+
h[k.to_sym] = v
|
118
|
+
}
|
102
119
|
|
103
|
-
if attributes.
|
120
|
+
if attributes.key?(:'_class')
|
104
121
|
self._class = attributes[:'_class']
|
105
122
|
end
|
106
123
|
|
107
|
-
if attributes.
|
108
|
-
self.display_name = attributes[:'
|
124
|
+
if attributes.key?(:'display_name')
|
125
|
+
self.display_name = attributes[:'display_name']
|
109
126
|
end
|
110
127
|
|
111
|
-
if attributes.
|
128
|
+
if attributes.key?(:'executors')
|
112
129
|
if (value = attributes[:'executors']).is_a?(Array)
|
113
130
|
self.executors = value
|
114
131
|
end
|
115
132
|
end
|
116
133
|
|
117
|
-
if attributes.
|
134
|
+
if attributes.key?(:'icon')
|
118
135
|
self.icon = attributes[:'icon']
|
119
136
|
end
|
120
137
|
|
121
|
-
if attributes.
|
122
|
-
self.icon_class_name = attributes[:'
|
138
|
+
if attributes.key?(:'icon_class_name')
|
139
|
+
self.icon_class_name = attributes[:'icon_class_name']
|
123
140
|
end
|
124
141
|
|
125
|
-
if attributes.
|
142
|
+
if attributes.key?(:'idle')
|
126
143
|
self.idle = attributes[:'idle']
|
127
144
|
end
|
128
145
|
|
129
|
-
if attributes.
|
130
|
-
self.jnlp_agent = attributes[:'
|
146
|
+
if attributes.key?(:'jnlp_agent')
|
147
|
+
self.jnlp_agent = attributes[:'jnlp_agent']
|
131
148
|
end
|
132
149
|
|
133
|
-
if attributes.
|
134
|
-
self.launch_supported = attributes[:'
|
150
|
+
if attributes.key?(:'launch_supported')
|
151
|
+
self.launch_supported = attributes[:'launch_supported']
|
135
152
|
end
|
136
153
|
|
137
|
-
if attributes.
|
138
|
-
self.load_statistics = attributes[:'
|
154
|
+
if attributes.key?(:'load_statistics')
|
155
|
+
self.load_statistics = attributes[:'load_statistics']
|
139
156
|
end
|
140
157
|
|
141
|
-
if attributes.
|
142
|
-
self.manual_launch_allowed = attributes[:'
|
158
|
+
if attributes.key?(:'manual_launch_allowed')
|
159
|
+
self.manual_launch_allowed = attributes[:'manual_launch_allowed']
|
143
160
|
end
|
144
161
|
|
145
|
-
if attributes.
|
146
|
-
self.monitor_data = attributes[:'
|
162
|
+
if attributes.key?(:'monitor_data')
|
163
|
+
self.monitor_data = attributes[:'monitor_data']
|
147
164
|
end
|
148
165
|
|
149
|
-
if attributes.
|
150
|
-
self.num_executors = attributes[:'
|
166
|
+
if attributes.key?(:'num_executors')
|
167
|
+
self.num_executors = attributes[:'num_executors']
|
151
168
|
end
|
152
169
|
|
153
|
-
if attributes.
|
170
|
+
if attributes.key?(:'offline')
|
154
171
|
self.offline = attributes[:'offline']
|
155
172
|
end
|
156
173
|
|
157
|
-
if attributes.
|
158
|
-
self.offline_cause = attributes[:'
|
174
|
+
if attributes.key?(:'offline_cause')
|
175
|
+
self.offline_cause = attributes[:'offline_cause']
|
159
176
|
end
|
160
177
|
|
161
|
-
if attributes.
|
162
|
-
self.offline_cause_reason = attributes[:'
|
178
|
+
if attributes.key?(:'offline_cause_reason')
|
179
|
+
self.offline_cause_reason = attributes[:'offline_cause_reason']
|
163
180
|
end
|
164
181
|
|
165
|
-
if attributes.
|
166
|
-
self.temporarily_offline = attributes[:'
|
182
|
+
if attributes.key?(:'temporarily_offline')
|
183
|
+
self.temporarily_offline = attributes[:'temporarily_offline']
|
167
184
|
end
|
168
|
-
|
169
185
|
end
|
170
186
|
|
171
187
|
# Show invalid properties with the reasons. Usually used together with valid?
|
172
|
-
# @return Array for valid
|
188
|
+
# @return Array for valid properties with the reasons
|
173
189
|
def list_invalid_properties
|
174
190
|
invalid_properties = Array.new
|
175
|
-
|
191
|
+
invalid_properties
|
176
192
|
end
|
177
193
|
|
178
194
|
# Check to see if the all the properties in the model are valid
|
179
195
|
# @return true if the model is valid
|
180
196
|
def valid?
|
181
|
-
|
197
|
+
true
|
182
198
|
end
|
183
199
|
|
184
200
|
# Checks equality by comparing each attribute.
|
@@ -211,26 +227,35 @@ module SwaggyJenkinsClient
|
|
211
227
|
end
|
212
228
|
|
213
229
|
# Calculates hash code according to all attributes.
|
214
|
-
# @return [
|
230
|
+
# @return [Integer] Hash code
|
215
231
|
def hash
|
216
232
|
[_class, display_name, executors, icon, icon_class_name, idle, jnlp_agent, launch_supported, load_statistics, manual_launch_allowed, monitor_data, num_executors, offline, offline_cause, offline_cause_reason, temporarily_offline].hash
|
217
233
|
end
|
218
234
|
|
235
|
+
# Builds the object from hash
|
236
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
237
|
+
# @return [Object] Returns the model itself
|
238
|
+
def self.build_from_hash(attributes)
|
239
|
+
new.build_from_hash(attributes)
|
240
|
+
end
|
241
|
+
|
219
242
|
# Builds the object from hash
|
220
243
|
# @param [Hash] attributes Model attributes in the form of hash
|
221
244
|
# @return [Object] Returns the model itself
|
222
245
|
def build_from_hash(attributes)
|
223
246
|
return nil unless attributes.is_a?(Hash)
|
224
|
-
self.class.
|
225
|
-
if
|
226
|
-
#
|
247
|
+
self.class.openapi_types.each_pair do |key, type|
|
248
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
249
|
+
self.send("#{key}=", nil)
|
250
|
+
elsif type =~ /\AArray<(.*)>/i
|
251
|
+
# check to ensure the input is an array given that the attribute
|
227
252
|
# is documented as an array but the input is not
|
228
253
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
229
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
254
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
230
255
|
end
|
231
256
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
232
257
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
233
|
-
end
|
258
|
+
end
|
234
259
|
end
|
235
260
|
|
236
261
|
self
|
@@ -242,8 +267,8 @@ module SwaggyJenkinsClient
|
|
242
267
|
# @return [Object] Deserialized data
|
243
268
|
def _deserialize(type, value)
|
244
269
|
case type.to_sym
|
245
|
-
when :
|
246
|
-
|
270
|
+
when :Time
|
271
|
+
Time.parse(value)
|
247
272
|
when :Date
|
248
273
|
Date.parse(value)
|
249
274
|
when :String
|
@@ -252,7 +277,7 @@ module SwaggyJenkinsClient
|
|
252
277
|
value.to_i
|
253
278
|
when :Float
|
254
279
|
value.to_f
|
255
|
-
when :
|
280
|
+
when :Boolean
|
256
281
|
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
257
282
|
true
|
258
283
|
else
|
@@ -273,8 +298,9 @@ module SwaggyJenkinsClient
|
|
273
298
|
end
|
274
299
|
end
|
275
300
|
else # model
|
276
|
-
|
277
|
-
|
301
|
+
# models (e.g. Pet) or oneOf
|
302
|
+
klass = SwaggyJenkinsClient.const_get(type)
|
303
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
278
304
|
end
|
279
305
|
end
|
280
306
|
|
@@ -296,7 +322,11 @@ module SwaggyJenkinsClient
|
|
296
322
|
hash = {}
|
297
323
|
self.class.attribute_map.each_pair do |attr, param|
|
298
324
|
value = self.send(attr)
|
299
|
-
|
325
|
+
if value.nil?
|
326
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
327
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
328
|
+
end
|
329
|
+
|
300
330
|
hash[param] = _to_hash(value)
|
301
331
|
end
|
302
332
|
hash
|
@@ -308,7 +338,7 @@ module SwaggyJenkinsClient
|
|
308
338
|
# @return [Hash] Returns the value in the form of hash
|
309
339
|
def _to_hash(value)
|
310
340
|
if value.is_a?(Array)
|
311
|
-
value.compact.map{ |v| _to_hash(v) }
|
341
|
+
value.compact.map { |v| _to_hash(v) }
|
312
342
|
elsif value.is_a?(Hash)
|
313
343
|
{}.tap do |hash|
|
314
344
|
value.each { |k, v| hash[k] = _to_hash(v) }
|