swaggy_jenkins 0.0.1 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- 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 QueueBlockedItem
|
18
18
|
attr_accessor :_class
|
19
19
|
|
@@ -39,7 +39,6 @@ module SwaggyJenkinsClient
|
|
39
39
|
|
40
40
|
attr_accessor :buildable_start_milliseconds
|
41
41
|
|
42
|
-
|
43
42
|
# Attribute mapping from ruby-style variable name to JSON key.
|
44
43
|
def self.attribute_map
|
45
44
|
{
|
@@ -58,17 +57,22 @@ module SwaggyJenkinsClient
|
|
58
57
|
}
|
59
58
|
end
|
60
59
|
|
60
|
+
# Returns all the JSON keys this model knows about
|
61
|
+
def self.acceptable_attributes
|
62
|
+
attribute_map.values
|
63
|
+
end
|
64
|
+
|
61
65
|
# Attribute type mapping.
|
62
|
-
def self.
|
66
|
+
def self.openapi_types
|
63
67
|
{
|
64
68
|
:'_class' => :'String',
|
65
69
|
:'actions' => :'Array<CauseAction>',
|
66
|
-
:'blocked' => :'
|
67
|
-
:'buildable' => :'
|
70
|
+
:'blocked' => :'Boolean',
|
71
|
+
:'buildable' => :'Boolean',
|
68
72
|
:'id' => :'Integer',
|
69
73
|
:'in_queue_since' => :'Integer',
|
70
74
|
:'params' => :'String',
|
71
|
-
:'stuck' => :'
|
75
|
+
:'stuck' => :'Boolean',
|
72
76
|
:'task' => :'FreeStyleProject',
|
73
77
|
:'url' => :'String',
|
74
78
|
:'why' => :'String',
|
@@ -76,77 +80,89 @@ module SwaggyJenkinsClient
|
|
76
80
|
}
|
77
81
|
end
|
78
82
|
|
83
|
+
# List of attributes with nullable: true
|
84
|
+
def self.openapi_nullable
|
85
|
+
Set.new([
|
86
|
+
])
|
87
|
+
end
|
88
|
+
|
79
89
|
# Initializes the object
|
80
90
|
# @param [Hash] attributes Model attributes in the form of hash
|
81
91
|
def initialize(attributes = {})
|
82
|
-
|
92
|
+
if (!attributes.is_a?(Hash))
|
93
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggyJenkinsClient::QueueBlockedItem` initialize method"
|
94
|
+
end
|
83
95
|
|
84
|
-
# convert string to symbol for hash key
|
85
|
-
attributes = attributes.each_with_object({}){|(k,v), h|
|
96
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
97
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
98
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
99
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggyJenkinsClient::QueueBlockedItem`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
100
|
+
end
|
101
|
+
h[k.to_sym] = v
|
102
|
+
}
|
86
103
|
|
87
|
-
if attributes.
|
104
|
+
if attributes.key?(:'_class')
|
88
105
|
self._class = attributes[:'_class']
|
89
106
|
end
|
90
107
|
|
91
|
-
if attributes.
|
108
|
+
if attributes.key?(:'actions')
|
92
109
|
if (value = attributes[:'actions']).is_a?(Array)
|
93
110
|
self.actions = value
|
94
111
|
end
|
95
112
|
end
|
96
113
|
|
97
|
-
if attributes.
|
114
|
+
if attributes.key?(:'blocked')
|
98
115
|
self.blocked = attributes[:'blocked']
|
99
116
|
end
|
100
117
|
|
101
|
-
if attributes.
|
118
|
+
if attributes.key?(:'buildable')
|
102
119
|
self.buildable = attributes[:'buildable']
|
103
120
|
end
|
104
121
|
|
105
|
-
if attributes.
|
122
|
+
if attributes.key?(:'id')
|
106
123
|
self.id = attributes[:'id']
|
107
124
|
end
|
108
125
|
|
109
|
-
if attributes.
|
110
|
-
self.in_queue_since = attributes[:'
|
126
|
+
if attributes.key?(:'in_queue_since')
|
127
|
+
self.in_queue_since = attributes[:'in_queue_since']
|
111
128
|
end
|
112
129
|
|
113
|
-
if attributes.
|
130
|
+
if attributes.key?(:'params')
|
114
131
|
self.params = attributes[:'params']
|
115
132
|
end
|
116
133
|
|
117
|
-
if attributes.
|
134
|
+
if attributes.key?(:'stuck')
|
118
135
|
self.stuck = attributes[:'stuck']
|
119
136
|
end
|
120
137
|
|
121
|
-
if attributes.
|
138
|
+
if attributes.key?(:'task')
|
122
139
|
self.task = attributes[:'task']
|
123
140
|
end
|
124
141
|
|
125
|
-
if attributes.
|
142
|
+
if attributes.key?(:'url')
|
126
143
|
self.url = attributes[:'url']
|
127
144
|
end
|
128
145
|
|
129
|
-
if attributes.
|
146
|
+
if attributes.key?(:'why')
|
130
147
|
self.why = attributes[:'why']
|
131
148
|
end
|
132
149
|
|
133
|
-
if attributes.
|
134
|
-
self.buildable_start_milliseconds = attributes[:'
|
150
|
+
if attributes.key?(:'buildable_start_milliseconds')
|
151
|
+
self.buildable_start_milliseconds = attributes[:'buildable_start_milliseconds']
|
135
152
|
end
|
136
|
-
|
137
153
|
end
|
138
154
|
|
139
155
|
# Show invalid properties with the reasons. Usually used together with valid?
|
140
|
-
# @return Array for valid
|
156
|
+
# @return Array for valid properties with the reasons
|
141
157
|
def list_invalid_properties
|
142
158
|
invalid_properties = Array.new
|
143
|
-
|
159
|
+
invalid_properties
|
144
160
|
end
|
145
161
|
|
146
162
|
# Check to see if the all the properties in the model are valid
|
147
163
|
# @return true if the model is valid
|
148
164
|
def valid?
|
149
|
-
|
165
|
+
true
|
150
166
|
end
|
151
167
|
|
152
168
|
# Checks equality by comparing each attribute.
|
@@ -175,26 +191,35 @@ module SwaggyJenkinsClient
|
|
175
191
|
end
|
176
192
|
|
177
193
|
# Calculates hash code according to all attributes.
|
178
|
-
# @return [
|
194
|
+
# @return [Integer] Hash code
|
179
195
|
def hash
|
180
196
|
[_class, actions, blocked, buildable, id, in_queue_since, params, stuck, task, url, why, buildable_start_milliseconds].hash
|
181
197
|
end
|
182
198
|
|
199
|
+
# Builds the object from hash
|
200
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
201
|
+
# @return [Object] Returns the model itself
|
202
|
+
def self.build_from_hash(attributes)
|
203
|
+
new.build_from_hash(attributes)
|
204
|
+
end
|
205
|
+
|
183
206
|
# Builds the object from hash
|
184
207
|
# @param [Hash] attributes Model attributes in the form of hash
|
185
208
|
# @return [Object] Returns the model itself
|
186
209
|
def build_from_hash(attributes)
|
187
210
|
return nil unless attributes.is_a?(Hash)
|
188
|
-
self.class.
|
189
|
-
if
|
190
|
-
#
|
211
|
+
self.class.openapi_types.each_pair do |key, type|
|
212
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
213
|
+
self.send("#{key}=", nil)
|
214
|
+
elsif type =~ /\AArray<(.*)>/i
|
215
|
+
# check to ensure the input is an array given that the attribute
|
191
216
|
# is documented as an array but the input is not
|
192
217
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
193
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
218
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
194
219
|
end
|
195
220
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
196
221
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
197
|
-
end
|
222
|
+
end
|
198
223
|
end
|
199
224
|
|
200
225
|
self
|
@@ -206,8 +231,8 @@ module SwaggyJenkinsClient
|
|
206
231
|
# @return [Object] Deserialized data
|
207
232
|
def _deserialize(type, value)
|
208
233
|
case type.to_sym
|
209
|
-
when :
|
210
|
-
|
234
|
+
when :Time
|
235
|
+
Time.parse(value)
|
211
236
|
when :Date
|
212
237
|
Date.parse(value)
|
213
238
|
when :String
|
@@ -216,7 +241,7 @@ module SwaggyJenkinsClient
|
|
216
241
|
value.to_i
|
217
242
|
when :Float
|
218
243
|
value.to_f
|
219
|
-
when :
|
244
|
+
when :Boolean
|
220
245
|
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
221
246
|
true
|
222
247
|
else
|
@@ -237,8 +262,9 @@ module SwaggyJenkinsClient
|
|
237
262
|
end
|
238
263
|
end
|
239
264
|
else # model
|
240
|
-
|
241
|
-
|
265
|
+
# models (e.g. Pet) or oneOf
|
266
|
+
klass = SwaggyJenkinsClient.const_get(type)
|
267
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
242
268
|
end
|
243
269
|
end
|
244
270
|
|
@@ -260,7 +286,11 @@ module SwaggyJenkinsClient
|
|
260
286
|
hash = {}
|
261
287
|
self.class.attribute_map.each_pair do |attr, param|
|
262
288
|
value = self.send(attr)
|
263
|
-
|
289
|
+
if value.nil?
|
290
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
291
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
292
|
+
end
|
293
|
+
|
264
294
|
hash[param] = _to_hash(value)
|
265
295
|
end
|
266
296
|
hash
|
@@ -272,7 +302,7 @@ module SwaggyJenkinsClient
|
|
272
302
|
# @return [Hash] Returns the value in the form of hash
|
273
303
|
def _to_hash(value)
|
274
304
|
if value.is_a?(Array)
|
275
|
-
value.compact.map{ |v| _to_hash(v) }
|
305
|
+
value.compact.map { |v| _to_hash(v) }
|
276
306
|
elsif value.is_a?(Hash)
|
277
307
|
{}.tap do |hash|
|
278
308
|
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 QueueItemImpl
|
18
18
|
attr_accessor :_class
|
19
19
|
|
@@ -25,7 +25,6 @@ module SwaggyJenkinsClient
|
|
25
25
|
|
26
26
|
attr_accessor :queued_time
|
27
27
|
|
28
|
-
|
29
28
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
29
|
def self.attribute_map
|
31
30
|
{
|
@@ -37,8 +36,13 @@ module SwaggyJenkinsClient
|
|
37
36
|
}
|
38
37
|
end
|
39
38
|
|
39
|
+
# Returns all the JSON keys this model knows about
|
40
|
+
def self.acceptable_attributes
|
41
|
+
attribute_map.values
|
42
|
+
end
|
43
|
+
|
40
44
|
# Attribute type mapping.
|
41
|
-
def self.
|
45
|
+
def self.openapi_types
|
42
46
|
{
|
43
47
|
:'_class' => :'String',
|
44
48
|
:'expected_build_number' => :'Integer',
|
@@ -48,47 +52,59 @@ module SwaggyJenkinsClient
|
|
48
52
|
}
|
49
53
|
end
|
50
54
|
|
55
|
+
# List of attributes with nullable: true
|
56
|
+
def self.openapi_nullable
|
57
|
+
Set.new([
|
58
|
+
])
|
59
|
+
end
|
60
|
+
|
51
61
|
# Initializes the object
|
52
62
|
# @param [Hash] attributes Model attributes in the form of hash
|
53
63
|
def initialize(attributes = {})
|
54
|
-
|
64
|
+
if (!attributes.is_a?(Hash))
|
65
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggyJenkinsClient::QueueItemImpl` initialize method"
|
66
|
+
end
|
55
67
|
|
56
|
-
# convert string to symbol for hash key
|
57
|
-
attributes = attributes.each_with_object({}){|(k,v), h|
|
68
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
69
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
70
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
71
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggyJenkinsClient::QueueItemImpl`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
72
|
+
end
|
73
|
+
h[k.to_sym] = v
|
74
|
+
}
|
58
75
|
|
59
|
-
if attributes.
|
76
|
+
if attributes.key?(:'_class')
|
60
77
|
self._class = attributes[:'_class']
|
61
78
|
end
|
62
79
|
|
63
|
-
if attributes.
|
64
|
-
self.expected_build_number = attributes[:'
|
80
|
+
if attributes.key?(:'expected_build_number')
|
81
|
+
self.expected_build_number = attributes[:'expected_build_number']
|
65
82
|
end
|
66
83
|
|
67
|
-
if attributes.
|
84
|
+
if attributes.key?(:'id')
|
68
85
|
self.id = attributes[:'id']
|
69
86
|
end
|
70
87
|
|
71
|
-
if attributes.
|
88
|
+
if attributes.key?(:'pipeline')
|
72
89
|
self.pipeline = attributes[:'pipeline']
|
73
90
|
end
|
74
91
|
|
75
|
-
if attributes.
|
76
|
-
self.queued_time = attributes[:'
|
92
|
+
if attributes.key?(:'queued_time')
|
93
|
+
self.queued_time = attributes[:'queued_time']
|
77
94
|
end
|
78
|
-
|
79
95
|
end
|
80
96
|
|
81
97
|
# Show invalid properties with the reasons. Usually used together with valid?
|
82
|
-
# @return Array for valid
|
98
|
+
# @return Array for valid properties with the reasons
|
83
99
|
def list_invalid_properties
|
84
100
|
invalid_properties = Array.new
|
85
|
-
|
101
|
+
invalid_properties
|
86
102
|
end
|
87
103
|
|
88
104
|
# Check to see if the all the properties in the model are valid
|
89
105
|
# @return true if the model is valid
|
90
106
|
def valid?
|
91
|
-
|
107
|
+
true
|
92
108
|
end
|
93
109
|
|
94
110
|
# Checks equality by comparing each attribute.
|
@@ -110,26 +126,35 @@ module SwaggyJenkinsClient
|
|
110
126
|
end
|
111
127
|
|
112
128
|
# Calculates hash code according to all attributes.
|
113
|
-
# @return [
|
129
|
+
# @return [Integer] Hash code
|
114
130
|
def hash
|
115
131
|
[_class, expected_build_number, id, pipeline, queued_time].hash
|
116
132
|
end
|
117
133
|
|
134
|
+
# Builds the object from hash
|
135
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
136
|
+
# @return [Object] Returns the model itself
|
137
|
+
def self.build_from_hash(attributes)
|
138
|
+
new.build_from_hash(attributes)
|
139
|
+
end
|
140
|
+
|
118
141
|
# Builds the object from hash
|
119
142
|
# @param [Hash] attributes Model attributes in the form of hash
|
120
143
|
# @return [Object] Returns the model itself
|
121
144
|
def build_from_hash(attributes)
|
122
145
|
return nil unless attributes.is_a?(Hash)
|
123
|
-
self.class.
|
124
|
-
if
|
125
|
-
#
|
146
|
+
self.class.openapi_types.each_pair do |key, type|
|
147
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
148
|
+
self.send("#{key}=", nil)
|
149
|
+
elsif type =~ /\AArray<(.*)>/i
|
150
|
+
# check to ensure the input is an array given that the attribute
|
126
151
|
# is documented as an array but the input is not
|
127
152
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
128
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
153
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
129
154
|
end
|
130
155
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
131
156
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
132
|
-
end
|
157
|
+
end
|
133
158
|
end
|
134
159
|
|
135
160
|
self
|
@@ -141,8 +166,8 @@ module SwaggyJenkinsClient
|
|
141
166
|
# @return [Object] Deserialized data
|
142
167
|
def _deserialize(type, value)
|
143
168
|
case type.to_sym
|
144
|
-
when :
|
145
|
-
|
169
|
+
when :Time
|
170
|
+
Time.parse(value)
|
146
171
|
when :Date
|
147
172
|
Date.parse(value)
|
148
173
|
when :String
|
@@ -151,7 +176,7 @@ module SwaggyJenkinsClient
|
|
151
176
|
value.to_i
|
152
177
|
when :Float
|
153
178
|
value.to_f
|
154
|
-
when :
|
179
|
+
when :Boolean
|
155
180
|
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
156
181
|
true
|
157
182
|
else
|
@@ -172,8 +197,9 @@ module SwaggyJenkinsClient
|
|
172
197
|
end
|
173
198
|
end
|
174
199
|
else # model
|
175
|
-
|
176
|
-
|
200
|
+
# models (e.g. Pet) or oneOf
|
201
|
+
klass = SwaggyJenkinsClient.const_get(type)
|
202
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
177
203
|
end
|
178
204
|
end
|
179
205
|
|
@@ -195,7 +221,11 @@ module SwaggyJenkinsClient
|
|
195
221
|
hash = {}
|
196
222
|
self.class.attribute_map.each_pair do |attr, param|
|
197
223
|
value = self.send(attr)
|
198
|
-
|
224
|
+
if value.nil?
|
225
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
226
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
227
|
+
end
|
228
|
+
|
199
229
|
hash[param] = _to_hash(value)
|
200
230
|
end
|
201
231
|
hash
|
@@ -207,7 +237,7 @@ module SwaggyJenkinsClient
|
|
207
237
|
# @return [Hash] Returns the value in the form of hash
|
208
238
|
def _to_hash(value)
|
209
239
|
if value.is_a?(Array)
|
210
|
-
value.compact.map{ |v| _to_hash(v) }
|
240
|
+
value.compact.map { |v| _to_hash(v) }
|
211
241
|
elsif value.is_a?(Hash)
|
212
242
|
{}.tap do |hash|
|
213
243
|
value.each { |k, v| hash[k] = _to_hash(v) }
|