1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef _unotools_JAVAOPTIONS_HXX
24 #define _unotools_JAVAOPTIONS_HXX
25 
26 #include "unotools/unotoolsdllapi.h"
27 #include <sal/types.h>
28 #include <unotools/configitem.hxx>
29 
30 
31 // class SvtJavaOptions --------------------------------------------------
32 
33 struct SvtJavaOptions_Impl;
34 
35 class UNOTOOLS_DLLPUBLIC SvtJavaOptions : public utl::ConfigItem
36 {
37     SvtJavaOptions_Impl* pImpl;
38 public:
39     enum EOption
40     {
41         E_ENABLED,
42         E_SECURITY,
43         E_NETACCESS,
44         E_USERCLASSPATH,
45         E_EXECUTEAPPLETS
46     };
47 
48     SvtJavaOptions();
49     ~SvtJavaOptions();
50 
51     virtual void    Commit();
52 
53     sal_Bool        IsEnabled() const;
54     sal_Bool        IsSecurity()const;
55     sal_Int32       GetNetAccess() const;
56     rtl::OUString&  GetUserClassPath()const;
57     sal_Bool        IsExecuteApplets() const;
58 
59     void SetEnabled(sal_Bool bSet) ;
60     void SetSecurity(sal_Bool bSet);
61     void SetNetAccess(sal_Int32 nSet) ;
62     void SetUserClassPath(const rtl::OUString& rSet);
63     void SetExecuteApplets(sal_Bool bSet);
64 
65     sal_Bool IsReadOnly( EOption eOption ) const;
66 };
67 
68 #endif //
69 
70