AlterOffice
AlterOffice 3.4 SDK C/C++ API Reference
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
security_decl.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 
3 
4 #ifndef INCLUDED_OSL_SECURITY_DECL_HXX
5 #define INCLUDED_OSL_SECURITY_DECL_HXX
6 
7 #include "rtl/ustring.hxx"
8 #include "osl/security.h"
9 
10 namespace osl
11 {
12 
18 class Security
19 {
20 protected:
22 
23 public:
24  inline Security();
25  inline ~Security();
26 
36  inline bool SAL_CALL logonUser(const rtl::OUString& strName,
37  const rtl::OUString& strPasswd);
38 
56  inline bool SAL_CALL logonUser(const rtl::OUString & strName,
57  const rtl::OUString & strPasswd,
58  const rtl::OUString & strFileServer);
59 
67  inline bool SAL_CALL getUserIdent( rtl::OUString& strIdent) const;
68 
78  inline bool SAL_CALL getUserName( rtl::OUString& strName, bool bIncludeDomain=true ) const;
79 
86  inline bool SAL_CALL getHomeDir( rtl::OUString& strDirectory) const;
87 
95  inline bool SAL_CALL getConfigDir( rtl::OUString & strDirectory) const;
96 
102  inline bool SAL_CALL isAdministrator() const;
103 
106  inline oslSecurity getHandle() const;
107 };
108 
109 }
110 
111 #endif // INCLUDED_OSL_SECURITY_DECL_HXX
112 
113 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
oslSecurity getHandle() const
Returns the underlying oslSecurity handle.
Definition: security.hxx:80
This String class provides base functionality for C++ like Unicode character array handling...
Definition: ustring.hxx:182
bool getUserName(rtl::OUString &strName, bool bIncludeDomain=true) const
get the name of the logged in user.
Definition: security.hxx:56
bool getUserIdent(rtl::OUString &strIdent) const
get the ident of the logged in user.
Definition: security.hxx:50
Encapsulate security information for one user.
Definition: security_decl.hxx:18
oslSecurity m_handle
Definition: security_decl.hxx:21
~Security()
Definition: security.hxx:22
void * oslSecurity
Process handle.
Definition: security.h:29
bool logonUser(const rtl::OUString &strName, const rtl::OUString &strPasswd)
get the security information for one user.
Definition: security.hxx:27
Security()
Definition: security.hxx:17
bool getConfigDir(rtl::OUString &strDirectory) const
get the directory for configuration data of the logged in user.
Definition: security.hxx:70
bool getHomeDir(rtl::OUString &strDirectory) const
get the home directory of the logged in user.
Definition: security.hxx:64
bool isAdministrator() const
Query if the user who is logged in has administrator rights.
Definition: security.hxx:75