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

common-workflow-language / cwljava / #352

07 Apr 2025 10:22AM UTC coverage: 59.538% (-0.6%) from 60.167%
#352

Pull #193

github

web-flow
Merge d636f9333 into 46536cad2
Pull Request #193: Add accessor for the extension field.

0 of 129 new or added lines in 129 files covered. (0.0%)

7347 of 12340 relevant lines covered (59.54%)

0.6 hits per line

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

77.14
/src/main/java/org/w3id/cwl/cwl1_1/LoadListingRequirementImpl.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.w3id.cwl.cwl1_1;
16

17
import org.w3id.cwl.cwl1_1.utils.LoaderInstances;
18
import org.w3id.cwl.cwl1_1.utils.LoadingOptions;
19
import org.w3id.cwl.cwl1_1.utils.LoadingOptionsBuilder;
20
import org.w3id.cwl.cwl1_1.utils.SaveableImpl;
21
import org.w3id.cwl.cwl1_1.utils.ValidationException;
22

23
/**
24
* Auto-generated class implementation for <I>https://w3id.org/cwl/cwl#LoadListingRequirement</I><BR> <BLOCKQUOTE>
25
 Specify the desired behavior for loading the `listing` field of
26
 a Directory object for use by expressions.
27
  </BLOCKQUOTE>
28
 */
29
public class LoadListingRequirementImpl extends SaveableImpl implements LoadListingRequirement {
30
  private LoadingOptions loadingOptions_ = new LoadingOptionsBuilder().build();
1✔
31
  private java.util.Map<String, Object> extensionFields_ =
1✔
32
      new java.util.HashMap<String, Object>();
33
  public java.util.Map<String, Object> getExtensionFields() {
NEW
34
    return this.extensionFields_;
×
35
  }
36

37
  private LoadListingRequirement_class class_;
38

39
  /**
40
   * Getter for property <I>https://w3id.org/cwl/cwl#LoadListingRequirement/class</I><BR>
41
   * <BLOCKQUOTE>
42
   * Always 'LoadListingRequirement'   * </BLOCKQUOTE>
43
   */
44

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

49
  private java.util.Optional<LoadListingEnum> loadListing;
50

51
  /**
52
   * Getter for property <I>https://w3id.org/cwl/cwl#LoadListingRequirement/loadListing</I><BR>
53

54
   */
55

56
  public java.util.Optional<LoadListingEnum> getLoadListing() {
57
    return this.loadListing;
×
58
  }
59

60
  /**
61
   * Used by {@link org.w3id.cwl.cwl1_1.utils.RootLoader} to construct instances of LoadListingRequirementImpl.
62
   *
63
   * @param __doc_            Document fragment to load this record object from (presumably a
64
                              {@link java.util.Map}).
65
   * @param __baseUri_        Base URI to generate child document IDs against.
66
   * @param __loadingOptions  Context for loading URIs and populating objects.
67
   * @param __docRoot_        ID at this position in the document (if available) (maybe?)
68
   * @throws ValidationException If the document fragment is not a {@link java.util.Map}
69
   *                             or validation of fields fails.
70
   */
71
  public LoadListingRequirementImpl(
72
      final Object __doc_,
73
      final String __baseUri_,
74
      LoadingOptions __loadingOptions,
75
      final String __docRoot_) {
76
    super(__doc_, __baseUri_, __loadingOptions, __docRoot_);
1✔
77
    // Prefix plumbing variables with '__' to reduce likelihood of collision with
78
    // generated names.
79
    String __baseUri = __baseUri_;
1✔
80
    String __docRoot = __docRoot_;
1✔
81
    if (!(__doc_ instanceof java.util.Map)) {
1✔
82
      throw new ValidationException("LoadListingRequirementImpl called on non-map");
×
83
    }
84
    final java.util.Map<String, Object> __doc = (java.util.Map<String, Object>) __doc_;
1✔
85
    final java.util.List<ValidationException> __errors =
1✔
86
        new java.util.ArrayList<ValidationException>();
87
    if (__loadingOptions != null) {
1✔
88
      this.loadingOptions_ = __loadingOptions;
1✔
89
    }
90
    LoadListingRequirement_class class_;
91
    try {
92
      class_ =
1✔
93
          LoaderInstances
94
              .uri_LoadListingRequirement_class_False_True_None_None
95
              .loadField(__doc.get("class"), __baseUri, __loadingOptions);
1✔
96
    } catch (ValidationException e) {
1✔
97
      class_ = null; // won't be used but prevents compiler from complaining.
1✔
98
      final String __message = "the `class` field is not valid because:";
1✔
99
      __errors.add(new ValidationException(__message, e));
1✔
100
    }
1✔
101
    java.util.Optional<LoadListingEnum> loadListing;
102

103
    if (__doc.containsKey("loadListing")) {
1✔
104
      try {
105
        loadListing =
1✔
106
            LoaderInstances
107
                .optional_LoadListingEnum
108
                .loadField(__doc.get("loadListing"), __baseUri, __loadingOptions);
1✔
109
      } catch (ValidationException e) {
×
110
        loadListing = null; // won't be used but prevents compiler from complaining.
×
111
        final String __message = "the `loadListing` field is not valid because:";
×
112
        __errors.add(new ValidationException(__message, e));
×
113
      }
1✔
114

115
    } else {
116
      loadListing = null;
1✔
117
    }
118
    if (!__errors.isEmpty()) {
1✔
119
      throw new ValidationException("Trying 'RecordField'", __errors);
1✔
120
    }
121
    this.class_ = (LoadListingRequirement_class) class_;
1✔
122
    this.loadListing = (java.util.Optional<LoadListingEnum>) loadListing;
1✔
123
  }
1✔
124
}
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

© 2026 Coveralls, Inc