KeePass Help Center KeePass Home | Downloads | Translations | Plugins | Donate 
Help Center Home | Forums | Awards | Links 







IKpCommandLine Struct Referenceabstract

Interface to a command line handling object. More...

#include <IKpCommandLine.h>

Inheritance diagram for IKpCommandLine:
IKpUnknown

Public Member Functions

virtual LPCTSTR GetFullCommandLine ()=0
 Get the complete command line string for the KeePass process. More...
 
virtual LPCTSTR GetExecutablePath ()=0
 Get the path of the KeePass executable file. More...
 
virtual LPCTSTR GetOption (LPCTSTR lpName)=0
 Get a command line option's value. More...
 
virtual LPCTSTR GetMultiOption (LPCTSTR lpName, DWORD dwRelIndex)=0
 Get a command line option's value; for options that may appear multiple times in the command line. More...
 
virtual LPCTSTR GetToken (DWORD dwIndex)=0
 Get a command line token (option name and value). More...
 
virtual LPCTSTR GetTokenRel (LPCTSTR lpName, DWORD dwRelIndex)=0
 Get a command line token (option name and value); tokens are identified relatively by an index into the subset of tokens with the specified command line option name. More...
 
virtual LPCTSTR GetFilePath ()=0
 Get the file path specified on the command line. More...
 
virtual LPCTSTR GetPassword ()=0
 Get the password specified on the command line. More...
 
virtual LPCTSTR GetKeyFilePath ()=0
 Get the key file path specified on the command line. More...
 
virtual BOOL IsPreselectEnabled ()=0
 Returns whether the '-preselect' option is present in the command line or not. More...
 
virtual BOOL IsReadOnlyEnabled ()=0
 Returns whether the '-readonly' option is present in the command line or not. More...
 
virtual BOOL ArgumentBeginsWithPrefix (LPCTSTR lpArgument)=0
 Determine whether an argument begins with a prefix character. More...
 
- Public Member Functions inherited from IKpUnknown
virtual HRESULT QueryInterface (REFIID riid, void **ppvObject)=0
 COM infrastructure, provides access to all interfaces supported by this object. More...
 
virtual ULONG AddRef ()=0
 COM infrastructure, increments the reference count for this object. More...
 
virtual ULONG Release ()=0
 COM infrastructure, decrements the reference count for this object and eventually deletes it. More...
 

Detailed Description

Interface to a command line handling object.

Use IKpAPI::QueryInstance to retrieve an interface to a singleton object in KeePass handling command line queries.

Member Function Documentation

◆ ArgumentBeginsWithPrefix()

virtual BOOL IKpCommandLine::ArgumentBeginsWithPrefix ( LPCTSTR  lpArgument)
pure virtual

Determine whether an argument begins with a prefix character.

◆ GetExecutablePath()

virtual LPCTSTR IKpCommandLine::GetExecutablePath ( )
pure virtual

Get the path of the KeePass executable file.

Returns
Full executable path.
This string is static in KeePass, do not delete it.

◆ GetFilePath()

virtual LPCTSTR IKpCommandLine::GetFilePath ( )
pure virtual

Get the file path specified on the command line.

This typically is a path to a KDB database file.

Returns
Full path to the file. If no file has been specified, the string is empty.
This string is static in KeePass, do not delete it.

◆ GetFullCommandLine()

virtual LPCTSTR IKpCommandLine::GetFullCommandLine ( )
pure virtual

Get the complete command line string for the KeePass process.

Returns
This string is static in KeePass, do not delete it.

◆ GetKeyFilePath()

virtual LPCTSTR IKpCommandLine::GetKeyFilePath ( )
pure virtual

Get the key file path specified on the command line.

Returns
The key file path.
This string is static in KeePass, do not delete it.

◆ GetMultiOption()

virtual LPCTSTR IKpCommandLine::GetMultiOption ( LPCTSTR  lpName,
DWORD  dwRelIndex 
)
pure virtual

Get a command line option's value; for options that may appear multiple times in the command line.

To enumerate all options, call this method with increasing index until you get back NULL.

Parameters
lpNameName of the command line option/switch.
dwRelIndexZero-based relative index of the requested command line option/switch. Relative means the index of the requested option in the subset of all options with the specified name.
Returns
NULL, if the option is not present in the command line.
Non-NULL, the option's value, if the option is present in the command line. If no value is specified (command line switch), the string is empty.
This string is static in KeePass, do not delete it.

◆ GetOption()

virtual LPCTSTR IKpCommandLine::GetOption ( LPCTSTR  lpName)
pure virtual

Get a command line option's value.

Parameters
lpNameName of the command line option/switch.
Returns
NULL, if the option is not present in the command line.
Non-NULL, the option's value, if the option is present in the command line. If no value is specified (command line switch), the string is empty.
This string is static in KeePass, do not delete it.

◆ GetPassword()

virtual LPCTSTR IKpCommandLine::GetPassword ( )
pure virtual

Get the password specified on the command line.

Returns
The specified password.
This string is static in KeePass, do not delete it.

◆ GetToken()

virtual LPCTSTR IKpCommandLine::GetToken ( DWORD  dwIndex)
pure virtual

Get a command line token (option name and value).

To enumerate all tokens, call this method with increasing index until you get back NULL.

Parameters
dwIndexIndex of the command line token to get.
Returns
NULL, if the token is not present in the command line.
Non-NULL, the token, if the token is present in the command line.
This string is static in KeePass, do not delete it.

◆ GetTokenRel()

virtual LPCTSTR IKpCommandLine::GetTokenRel ( LPCTSTR  lpName,
DWORD  dwRelIndex 
)
pure virtual

Get a command line token (option name and value); tokens are identified relatively by an index into the subset of tokens with the specified command line option name.

To enumerate all tokens, call this method with increasing index until you get back NULL.

Parameters
lpNameName of the command line option/switch.
dwRelIndexZero-based relative index of the requested command line token. Relative means the index of the requested token in the subset of all token with the specified option name.
Returns
NULL, if the token is not present in the command line.
Non-NULL, the token's value, if the token is present in the command line.
This string is static in KeePass, do not delete it.

◆ IsPreselectEnabled()

virtual BOOL IKpCommandLine::IsPreselectEnabled ( )
pure virtual

Returns whether the '-preselect' option is present in the command line or not.

◆ IsReadOnlyEnabled()

virtual BOOL IKpCommandLine::IsReadOnlyEnabled ( )
pure virtual

Returns whether the '-readonly' option is present in the command line or not.


The documentation for this struct was generated from the following file:

Documentation generated with Doxygen.





Get KeePass