• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

common-workflow-language / cwljava / #423

17 Dec 2025 10:33AM UTC coverage: 56.982% (-1.0%) from 57.972%
#423

push

github

web-flow
refresh 2025-12 (including extensions) (#218)

* "id" is a required field in for Parameters and WorkflowSteps
* regen; drop CommandLineBindableImpl; add optional CWL extensions

185 of 577 new or added lines in 21 files covered. (32.06%)

10 existing lines in 10 files now uncovered.

7892 of 13850 relevant lines covered (56.98%)

0.57 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

51.22
/src/main/java/org/commonwl/cwlsdk/cwl1_2/SecretsImpl.java
1
// Copyright Common Workflow Language project contributors
2
//
3
// Licensed under the Apache License, Version 2.0 (the "License");
4
// you may not use this file except in compliance with the License.
5
// You may obtain a copy of the License at
6
//
7
//      http://www.apache.org/licenses/LICENSE-2.0
8
//
9
// Unless required by applicable law or agreed to in writing, software
10
// distributed under the License is distributed on an "AS IS" BASIS,
11
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
// See the License for the specific language governing permissions and
13
// limitations under the License.
14

15
package org.commonwl.cwlsdk.cwl1_2;
16

17
import org.commonwl.cwlsdk.cwl1_2.utils.LoaderInstances;
18
import org.commonwl.cwlsdk.cwl1_2.utils.LoadingOptions;
19
import org.commonwl.cwlsdk.cwl1_2.utils.LoadingOptionsBuilder;
20
import org.commonwl.cwlsdk.cwl1_2.utils.SaveableImpl;
21
import org.commonwl.cwlsdk.cwl1_2.utils.ValidationException;
22

23
/**
24
* Auto-generated class implementation for <I>http://commonwl.org/cwltool#Secrets</I><BR>
25
 */
26
public class SecretsImpl extends SaveableImpl implements Secrets {
27
  private LoadingOptions loadingOptions_ = new LoadingOptionsBuilder().build();
1✔
28
  private java.util.Map<String, Object> extensionFields_ =
1✔
29
      new java.util.HashMap<String, Object>();
30
  public LoadingOptions getLoadingOptions() {
31
    return this.loadingOptions_;
×
32
  }
33
  public java.util.Map<String, Object> getExtensionFields() {
34
    return this.extensionFields_;
×
35
  }
36

37
  private String class_;
38

39
  /**
40
   * Getter for property <I>http://commonwl.org/cwltool#Secrets/class</I><BR>
41
   * <BLOCKQUOTE>
42
   * Always &#x27;Secrets&#x27;   * </BLOCKQUOTE>
43
   */
44

45
  public String getClass_() {
NEW
46
    return this.class_;
×
47
  }
48

49
  private java.util.List<String> secrets;
50

51
  /**
52
   * Getter for property <I>http://commonwl.org/cwltool#Secrets/secrets</I><BR>
53
   * <BLOCKQUOTE>
54
   * List one or more input parameters that are sensitive (such as passwords)
55
   * which will be deliberately obscured from logging.
56
   *    * </BLOCKQUOTE>
57
   */
58

59
  public java.util.List<String> getSecrets() {
NEW
60
    return this.secrets;
×
61
  }
62

63
  /**
64
   * Used by {@link org.commonwl.cwlsdk.cwl1_2.utils.RootLoader} to construct instances of SecretsImpl.
65
   *
66
   * @param __doc_            Document fragment to load this record object from (presumably a
67
                              {@link java.util.Map}).
68
   * @param __baseUri_        Base URI to generate child document IDs against.
69
   * @param __loadingOptions  Context for loading URIs and populating objects.
70
   * @param __docRoot_        ID at this position in the document (if available) (maybe?)
71
   * @throws ValidationException If the document fragment is not a {@link java.util.Map}
72
   *                             or validation of fields fails.
73
   */
74
  public SecretsImpl(
75
      final Object __doc_,
76
      final String __baseUri_,
77
      LoadingOptions __loadingOptions,
78
      final String __docRoot_) {
79
    super(__doc_, __baseUri_, __loadingOptions, __docRoot_);
1✔
80
    // Prefix plumbing variables with '__' to reduce likelihood of collision with
81
    // generated names.
82
    String __baseUri = __baseUri_;
1✔
83
    String __docRoot = __docRoot_;
1✔
84
    if (!(__doc_ instanceof java.util.Map)) {
1✔
NEW
85
      throw new ValidationException("SecretsImpl called on non-map");
×
86
    }
87
    final java.util.Map<String, Object> __doc = (java.util.Map<String, Object>) __doc_;
1✔
88
    final java.util.List<ValidationException> __errors =
1✔
89
        new java.util.ArrayList<ValidationException>();
90
    if (__loadingOptions != null) {
1✔
91
      this.loadingOptions_ = __loadingOptions;
1✔
92
    }
93
    String class_;
94
    try {
95
      class_ =
1✔
96
          LoaderInstances
97
              .uri_StringInstance_False_True_None_None
98
              .loadField(__doc.get("class"), __baseUri, __loadingOptions);
1✔
NEW
99
    } catch (ValidationException e) {
×
NEW
100
      class_ = null; // won't be used but prevents compiler from complaining.
×
NEW
101
      final String __message = "the `class` field is not valid because:";
×
NEW
102
      __errors.add(new ValidationException(__message, e));
×
103
    }
1✔
104
    java.util.List<String> secrets;
105
    try {
106
      secrets =
1✔
107
          LoaderInstances
108
              .uri_array_of_StringInstance_False_False_0_None
NEW
109
              .loadField(__doc.get("secrets"), __baseUri, __loadingOptions);
×
110
    } catch (ValidationException e) {
1✔
111
      secrets = null; // won't be used but prevents compiler from complaining.
1✔
112
      final String __message = "the `secrets` field is not valid because:";
1✔
113
      __errors.add(new ValidationException(__message, e));
1✔
114
    }
×
115
    if (!__errors.isEmpty()) {
1✔
116
      throw new ValidationException("Trying 'RecordField'", __errors);
1✔
117
    }
NEW
118
    this.class_ = (String) class_;
×
NEW
119
    this.secrets = (java.util.List<String>) secrets;
×
120
    for (String field:__doc.keySet()) {
×
121
      if (!attrs.contains(field)) {
×
122
        if (field.contains(":")) {
×
123
          String expanded_field = __loadingOptions.expandUrl(field, "", false, false, null);
×
124
          extensionFields_.put(expanded_field, __doc.get(field));
×
125
        }
126
      }
127
    }
×
128
  }
×
129
  private java.util.List<String> attrs = java.util.Arrays.asList("class", "secrets");
1✔
130
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc