001/*
002 * SPDX-FileCopyrightText: none
003 * SPDX-License-Identifier: CC0-1.0
004 */
005
006package gov.nist.secauto.metaschema.cli.processor.command;
007
008import java.nio.file.Path;
009import java.nio.file.Paths;
010import java.util.Collection;
011import java.util.Collections;
012
013import edu.umd.cs.findbugs.annotations.NonNull;
014
015public abstract class AbstractTerminalCommand implements ICommand {
016
017  @SuppressWarnings("null")
018  @Override
019  public Collection<ICommand> getSubCommands() {
020    return Collections.emptyList();
021  }
022
023  @Override
024  public boolean isSubCommandRequired() {
025    return false;
026  }
027
028  protected static Path resolvePathAgainstCWD(@NonNull Path path) {
029    return Paths.get("").toAbsolutePath().resolve(path).normalize();
030  }
031}