\r
@param FileInfo The infotmation to set.\r
\r
- @retval EFI_SUCCESS The information was set.\r
+ @retval EFI_SUCCESS The information was set.\r
@retval EFI_UNSUPPORTED The InformationType is not known.\r
@retval EFI_NO_MEDIA The device has no medium.\r
@retval EFI_DEVICE_ERROR The device reported an error.\r
@param OpenMode the mode to open the file with.\r
@param Attributes the file's file attributes.\r
\r
- @retval EFI_SUCCESS The information was set.\r
+ @retval EFI_SUCCESS The information was set.\r
@retval EFI_INVALID_PARAMETER One of the parameters has an invalid value.\r
- @retval EFI_UNSUPPORTED Could not open the file path. \r
+ @retval EFI_UNSUPPORTED Could not open the file path. \r
@retval EFI_NOT_FOUND The specified file could not be found on the \r
device or the file system could not be found \r
on the device.\r
- @retval EFI_NO_MEDIA The device has no medium.\r
- @retval EFI_MEDIA_CHANGED The device has a different medium in it or the \r
+ @retval EFI_NO_MEDIA The device has no medium.\r
+ @retval EFI_MEDIA_CHANGED The device has a different medium in it or the \r
medium is no longer supported.\r
- @retval EFI_DEVICE_ERROR The device reported an error.\r
+ @retval EFI_DEVICE_ERROR The device reported an error.\r
@retval EFI_VOLUME_CORRUPTED The file system structures are corrupted.\r
- @retval EFI_WRITE_PROTECTED The file or medium is write protected.\r
- @retval EFI_ACCESS_DENIED The file was opened read only.\r
+ @retval EFI_WRITE_PROTECTED The file or medium is write protected.\r
+ @retval EFI_ACCESS_DENIED The file was opened read only.\r
@retval EFI_OUT_OF_RESOURCES Not enough resources were available to open the \r
file.\r
- @retval EFI_VOLUME_FULL The volume is full.\r
+ @retval EFI_VOLUME_FULL The volume is full.\r
**/\r
EFI_STATUS\r
EFIAPI\r
ShellOpenFileByName(\r
- IN CHAR16 *FilePath,\r
+ IN CONST CHAR16 *FilePath,\r
OUT EFI_FILE_HANDLE *FileHandle,\r
IN UINT64 OpenMode,\r
IN UINT64 Attributes\r
@retval EFI_NOT_FOUND The specified file could not be found on the \r
device or the file system could not be found \r
on the device.\r
- @retval EFI_NO_MEDIA The device has no medium.\r
- @retval EFI_MEDIA_CHANGED The device has a different medium in it or the \r
+ @retval EFI_NO_MEDIA The device has no medium.\r
+ @retval EFI_MEDIA_CHANGED The device has a different medium in it or the \r
medium is no longer supported.\r
- @retval EFI_DEVICE_ERROR The device reported an error.\r
+ @retval EFI_DEVICE_ERROR The device reported an error.\r
@retval EFI_VOLUME_CORRUPTED The file system structures are corrupted.\r
- @retval EFI_WRITE_PROTECTED The file or medium is write protected.\r
- @retval EFI_ACCESS_DENIED The file was opened read only.\r
+ @retval EFI_WRITE_PROTECTED The file or medium is write protected.\r
+ @retval EFI_ACCESS_DENIED The file was opened read only.\r
@retval EFI_OUT_OF_RESOURCES Not enough resources were available to open the \r
file.\r
- @retval EFI_VOLUME_FULL The volume is full.\r
+ @retval EFI_VOLUME_FULL The volume is full.\r
**/\r
EFI_STATUS\r
EFIAPI\r
ShellCreateDirectory(\r
- IN CHAR16 *DirectoryName,\r
+ IN CONST CHAR16 *DirectoryName,\r
OUT EFI_FILE_HANDLE *FileHandle\r
);\r
\r
\r
@param Buffer the buffer to put read data into.\r
\r
- @retval EFI_SUCCESS Data was read.\r
- @retval EFI_NO_MEDIA The device has no media.\r
- @retval EFI_DEVICE_ERROR The device reported an error.\r
- @retval EFI_VOLUME_CORRUPTED The file system structures are corrupted.\r
- @retval EFI_BUFFER_TO_SMALL Buffer is too small. ReadSize contains required \r
+ @retval EFI_SUCCESS Data was read.\r
+ @retval EFI_NO_MEDIA The device has no media.\r
+ @retval EFI_DEVICE_ERROR The device reported an error.\r
+ @retval EFI_VOLUME_CORRUPTED The file system structures are corrupted.\r
+ @retval EFI_BUFFER_TO_SMALL Buffer is too small. ReadSize contains required \r
size.\r
\r
**/\r
@param Buffer the buffer containing data to write is stored.\r
\r
@retval EFI_SUCCESS Data was written.\r
- @retval EFI_UNSUPPORTED Writes to an open directory are not supported.\r
+ @retval EFI_UNSUPPORTED Writes to an open directory are not supported.\r
@retval EFI_NO_MEDIA The device has no media.\r
- @retval EFI_DEVICE_ERROR The device reported an error.\r
+ @retval EFI_DEVICE_ERROR The device reported an error.\r
@retval EFI_VOLUME_CORRUPTED The file system structures are corrupted.\r
@retval EFI_WRITE_PROTECTED The device is write-protected.\r
- @retval EFI_ACCESS_DENIED The file was open for read only.\r
- @retval EFI_VOLUME_FULL The volume is full.\r
+ @retval EFI_ACCESS_DENIED The file was open for read only.\r
+ @retval EFI_VOLUME_FULL The volume is full.\r
**/\r
EFI_STATUS\r
EFIAPI\r
and will process '?' and '*' as such. the list must be freed with a call to \r
ShellCloseFileMetaArg().\r
\r
- If you are NOT appending to an existing list *ListHead must be NULL.\r
+ If you are NOT appending to an existing list *ListHead must be NULL. If \r
+ *ListHead is NULL then it must be callee freed.\r
\r
@param Arg pointer to path string\r
@param OpenMode mode to open files with\r
TypeFlag = 0,\r
TypeValue,\r
TypePosition,\r
+ TypeStart,\r
TypeMax,\r
} ParamType;\r
\r
**/\r
EFI_STATUS\r
EFIAPI\r
-ShellCommandLineParse (\r
+ShellCommandLineParseEx (\r
IN CONST SHELL_PARAM_ITEM *CheckList,\r
OUT LIST_ENTRY **CheckPackage,\r
OUT CHAR16 **ProblemParam OPTIONAL,\r
- IN BOOLEAN AutoPageBreak\r
+ IN BOOLEAN AutoPageBreak,\r
+ IN BOOLEAN AlwaysAllowNumbers\r
);\r
\r
+// make it easy to upgrade from older versions of the shell library.\r
+#define ShellCommandLineParse(CheckList,CheckPackage,ProblemParam,AutoPageBreak) ShellCommandLineParseEx(CheckList,CheckPackage,ProblemParam,AutoPageBreak,FALSE)\r
+\r
/**\r
Frees shell variable list that was returned from ShellCommandLineParse.\r
\r
IN UINT32 Position\r
);\r
\r
+/**\r
+ returns the number of command line value parameters that were parsed. \r
+ \r
+ this will not include flags.\r
+\r
+ @retval (UINTN)-1 No parsing has ocurred\r
+ @return other The number of value parameters found\r
+**/\r
+UINTN\r
+EFIAPI\r
+ShellCommandLineGetCount(\r
+ VOID\r
+ );\r
+\r
/**\r
This function causes the shell library to initialize itself. If the shell library\r
is already initialized it will de-initialize all the current protocol poitners and\r
...\r
);\r
\r
-#endif // __SHELL_LIB__
\ No newline at end of file
+/**\r
+ Print at a specific location on the screen.\r
+\r
+ This function will move the cursor to a given screen location, print the specified string, \r
+ and return the cursor to the original locaiton. \r
+ \r
+ If -1 is specified for either the Row or Col the current screen location for BOTH \r
+ will be used and the cursor's position will not be moved back to an original location.\r
+\r
+ if either Row or Col is out of range for the current console, then ASSERT\r
+ if Format is NULL, then ASSERT\r
+\r
+ In addition to the standard %-based flags as supported by UefiLib Print() this supports \r
+ the following additional flags:\r
+ %N - Set output attribute to normal\r
+ %H - Set output attribute to highlight\r
+ %E - Set output attribute to error\r
+ %B - Set output attribute to blue color\r
+ %V - Set output attribute to green color\r
+\r
+ Note: The background color is controlled by the shell command cls.\r
+\r
+ @param[in] Row the row to print at\r
+ @param[in] Col the column to print at\r
+ @param[in] HiiFormatStringId the format string Id for getting from Hii\r
+ @param[in] HiiFormatHandle the format string Handle for getting from Hii\r
+\r
+ @return the number of characters printed to the screen\r
+**/\r
+UINTN\r
+EFIAPI\r
+ShellPrintHiiEx(\r
+ IN INT32 Col OPTIONAL,\r
+ IN INT32 Row OPTIONAL,\r
+ IN CONST EFI_STRING_ID HiiFormatStringId,\r
+ IN CONST EFI_HANDLE HiiFormatHandle,\r
+ ...\r
+ );\r
+\r
+/**\r
+ Function to determine if a given filename represents a file or a directory.\r
+\r
+ @param[in] DirName Path to directory to test.\r
+\r
+ @retval EFI_SUCCESS The Path represents a directory\r
+ @retval EFI_NOT_FOUND The Path does not represent a directory\r
+ @return other The path failed to open\r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+ShellIsDirectory(\r
+ IN CONST CHAR16 *DirName\r
+ );\r
+\r
+\r
+#endif // __SHELL_LIB__\r