Skip to content

Commit

Permalink
Create Option.php
Browse files Browse the repository at this point in the history
  • Loading branch information
usernane committed Feb 15, 2024
1 parent 287b918 commit 197dbf9
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions webfiori/cli/Option.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?php

namespace webfiori\cli;

/**
* A class that holds the options which are used to configure command line argument.
*
* @author Ibrahim
*/
class Option {
/**
* An option which is used to tell if the argument is optional or not.
* Accepts 'true' or 'false' as its value.
*/
const OPTIONAL = 'optional';
/**
* An option which is used to set a default value for the argument if not
* provided and it was optional.
*/
const DEFAULT = 'default';
/**
* Help text of the argument. Used when the command 'help' is executed.
*/
const DESCRIPTION = 'description';
/**
* An array of values at which the argument can accept. Used to restrict
* the values that can be supplied to the argument.
*/
const VALUES = 'values';
}

0 comments on commit 197dbf9

Please sign in to comment.