Package com.sun.common.util.logging
Class LoggingConfigImpl
- java.lang.Object
-
- com.sun.common.util.logging.LoggingConfigImpl
-
- All Implemented Interfaces:
LoggingConfig,org.glassfish.hk2.api.PostConstruct
@Service @Contract public class LoggingConfigImpl extends Object implements LoggingConfig, org.glassfish.hk2.api.PostConstruct
Implementation of Logging Commands- Author:
- Naman Mehta
-
-
Constructor Summary
Constructors Constructor Description LoggingConfigImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringcreateZipFile(String sourceDir)StringcreateZipFile(String sourceDir, String zipFileName)voiddeleteLoggingProperties(Map<String,String> properties)voiddeleteLoggingProperties(Map<String,String> properties, String targetConfigName)Map<String,String>getDefaultLoggingProperties()StringgetLoggingFileDetails()StringgetLoggingFileDetails(String targetConfigName)Map<String,String>getLoggingProperties()Map<String,String>getLoggingProperties(String targetConfigName)voidpostConstruct()ConstructorStringsetLoggingProperty(String propertyName, String propertyValue)setLoggingProperty() sets an existing propertyName to be propertyValue if the property doesn't exist the property will be added.StringsetLoggingProperty(String propertyName, String propertyValue, String targetConfigName)setLoggingProperty() sets an existing propertyName to be propertyValue if the property doesn't exist the property will be added.voidsetupConfigDir(File file, File installDir)Map<String,String>updateLoggingProperties(Map<String,String> properties)Map<String,String>updateLoggingProperties(Map<String,String> properties, String targetConfigName)
-
-
-
Method Detail
-
postConstruct
public void postConstruct()
Constructor- Specified by:
postConstructin interfaceorg.glassfish.hk2.api.PostConstruct
-
setLoggingProperty
public String setLoggingProperty(String propertyName, String propertyValue) throws IOException
setLoggingProperty() sets an existing propertyName to be propertyValue if the property doesn't exist the property will be added. The logManager readConfiguration is not called in this method.- Specified by:
setLoggingPropertyin interfaceLoggingConfig- Parameters:
propertyName- Name of the property to setpropertyValue- Value to set- Throws:
IOException
-
setLoggingProperty
public String setLoggingProperty(String propertyName, String propertyValue, String targetConfigName) throws IOException
setLoggingProperty() sets an existing propertyName to be propertyValue if the property doesn't exist the property will be added. The logManager readConfiguration is not called in this method.- Specified by:
setLoggingPropertyin interfaceLoggingConfig- Parameters:
propertyName- Name of the property to setpropertyValue- Value to set- Throws:
IOException
-
updateLoggingProperties
public Map<String,String> updateLoggingProperties(Map<String,String> properties) throws IOException
- Specified by:
updateLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
updateLoggingProperties
public Map<String,String> updateLoggingProperties(Map<String,String> properties, String targetConfigName) throws IOException
- Specified by:
updateLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
getLoggingProperties
public Map<String,String> getLoggingProperties(String targetConfigName) throws IOException
- Specified by:
getLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
getLoggingProperties
public Map<String,String> getLoggingProperties() throws IOException
- Specified by:
getLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
deleteLoggingProperties
public void deleteLoggingProperties(Map<String,String> properties) throws IOException
- Specified by:
deleteLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
deleteLoggingProperties
public void deleteLoggingProperties(Map<String,String> properties, String targetConfigName) throws IOException
- Specified by:
deleteLoggingPropertiesin interfaceLoggingConfig- Throws:
IOException
-
createZipFile
public String createZipFile(String sourceDir) throws IOException
- Specified by:
createZipFilein interfaceLoggingConfig- Throws:
IOException
-
createZipFile
public String createZipFile(String sourceDir, String zipFileName) throws IOException
- Throws:
IOException
-
getLoggingFileDetails
public String getLoggingFileDetails() throws IOException
- Throws:
IOException
-
getLoggingFileDetails
public String getLoggingFileDetails(String targetConfigName) throws IOException
- Throws:
IOException
-
getDefaultLoggingProperties
public Map<String,String> getDefaultLoggingProperties() throws IOException
- Throws:
IOException
-
-