/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method * checking to see whether it returns an empty collection. Otherwise delegates to and * returns the value of the abstract {@link #containsOption(String)} method. */ @Override public final boolean containsProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { return !this.getNonOptionArgs().isEmpty(); } return this.containsOption(name); }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method * checking to see whether it returns an empty collection. Otherwise delegates to and * returns the value of the abstract {@link #containsOption(String)} method. */ @Override public final boolean containsProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { return !this.getNonOptionArgs().isEmpty(); } return this.containsOption(name); }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method. If so * and the collection of non-option arguments is empty, this method returns {@code * null}. If not empty, it returns a comma-separated String of all non-option * arguments. Otherwise delegates to and returns the result of the abstract {@link * #getOptionValues(String)} method. */ @Override @Nullable public final String getProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { Collection<String> nonOptionArguments = this.getNonOptionArgs(); if (nonOptionArguments.isEmpty()) { return null; } else { return StringUtils.collectionToCommaDelimitedString(nonOptionArguments); } } Collection<String> optionValues = this.getOptionValues(name); if (optionValues == null) { return null; } else { return StringUtils.collectionToCommaDelimitedString(optionValues); } }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method. If so * and the collection of non-option arguments is empty, this method returns {@code * null}. If not empty, it returns a comma-separated String of all non-option * arguments. Otherwise delegates to and returns the result of the abstract {@link * #getOptionValues(String)} method. */ @Override @Nullable public final String getProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { Collection<String> nonOptionArguments = this.getNonOptionArgs(); if (nonOptionArguments.isEmpty()) { return null; } else { return StringUtils.collectionToCommaDelimitedString(nonOptionArguments); } } Collection<String> optionValues = this.getOptionValues(name); if (optionValues == null) { return null; } else { return StringUtils.collectionToCommaDelimitedString(optionValues); } }
/** * Return whether this {@code PropertySource} contains a property with the given name. * <p>This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method * checking to see whether it returns an empty collection. Otherwise delegates to and * returns the value of the abstract {@link #containsOption(String)} method. */ @Override public final boolean containsProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { return !this.getNonOptionArgs().isEmpty(); } return this.containsOption(name); }
/** * {@inheritDoc} * <p>This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method. If so * and the collection of non-option arguments is empty, this method returns {@code * null}. If not empty, it returns a comma-separated String of all non-option * arguments. Otherwise delegates to and returns the result of the abstract {@link * #getOptionValues(String)} method. */ @Override public final String getProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { Collection<String> nonOptionArguments = this.getNonOptionArgs(); if (nonOptionArguments.isEmpty()) { return null; } else { return StringUtils.collectionToCommaDelimitedString(nonOptionArguments); } } Collection<String> optionValues = this.getOptionValues(name); if (optionValues == null) { return null; } else { return StringUtils.collectionToCommaDelimitedString(optionValues); } }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method * checking to see whether it returns an empty collection. Otherwise delegates to and * returns the value of the abstract {@link #containsOption(String)} method. */ @Override public final boolean containsProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { return !this.getNonOptionArgs().isEmpty(); } return this.containsOption(name); }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method * checking to see whether it returns an empty collection. Otherwise delegates to and * returns the value of the abstract {@link #containsOption(String)} method. */ @Override public final boolean containsProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { return !this.getNonOptionArgs().isEmpty(); } return this.containsOption(name); }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method. If so * and the collection of non-option arguments is empty, this method returns {@code * null}. If not empty, it returns a comma-separated String of all non-option * arguments. Otherwise delegates to and returns the result of the abstract {@link * #getOptionValues(String)} method. */ @Override @Nullable public final String getProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { Collection<String> nonOptionArguments = this.getNonOptionArgs(); if (nonOptionArguments.isEmpty()) { return null; } else { return StringUtils.collectionToCommaDelimitedString(nonOptionArguments); } } Collection<String> optionValues = this.getOptionValues(name); if (optionValues == null) { return null; } else { return StringUtils.collectionToCommaDelimitedString(optionValues); } }
/** * This implementation first checks to see if the name specified is the special * {@linkplain #setNonOptionArgsPropertyName(String) "non-option arguments" property}, * and if so delegates to the abstract {@link #getNonOptionArgs()} method. If so * and the collection of non-option arguments is empty, this method returns {@code * null}. If not empty, it returns a comma-separated String of all non-option * arguments. Otherwise delegates to and returns the result of the abstract {@link * #getOptionValues(String)} method. */ @Override @Nullable public final String getProperty(String name) { if (this.nonOptionArgsPropertyName.equals(name)) { Collection<String> nonOptionArguments = this.getNonOptionArgs(); if (nonOptionArguments.isEmpty()) { return null; } else { return StringUtils.collectionToCommaDelimitedString(nonOptionArguments); } } Collection<String> optionValues = this.getOptionValues(name); if (optionValues == null) { return null; } else { return StringUtils.collectionToCommaDelimitedString(optionValues); } }