public class RSStaticAndUser
extends java.lang.Object
The xbrl RS Home directory is where each application stores properties that may be subject to be used by the same application or other application of the same family. For example; the XBRLRepository.properties files stores information about how to open a connection with the XBRL Database. This information may be shared across multiple tools.
The algorithm to obtain the XBRL RS Home directory is the following: 1) The System property xbrl.rs.home is read. If there is no value then 2) The Environment variable XBRLRSHOME is read. If there is no value then 3) The user.home system property is used.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
longDateDateFormat
This is the format for dates using ISO8601 representation.
|
static java.lang.String |
RSEnvPropCatalogDir
This is the XBRL home directory stored in a system property
called xbrl.rs.home.
|
static java.lang.String |
RSEnvPropHomeDir
This is the XBRL home directory stored in a system property
called xbrl.rs.home.
|
static java.lang.String |
RSEnvVarHomeDir
If this the environment variable that, if defined, its value is
used rather than the value of the user.home property of the
java virtual machine while obtaining the path of a properties
file.
|
static java.lang.String |
RSHomeCatalogDir
This is the directory name under the "all users" installation folder where the catalog is installed.
|
static java.lang.String |
RSHomeDir
This is the directory name under the user.home property or XBRLRSHOME
environment property where properties files will be stored.
|
static java.lang.String |
shortDateDateFormat
This is the format for short dates across all tools.
|
Constructor and Description |
---|
RSStaticAndUser() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
createRSPropertiesDir()
Check if the directory for user's properties exists.
|
static java.lang.String |
findUserFileName(java.lang.String fileName)
Searches for a file with file name indicated in the fileName parameter in the following paths in order
The path returned by the readUserPath() method
The home directory
|
static java.lang.String |
getCatalogPath(java.lang.String fileName)
Calculates all possible path locations where the XBRLCatalogFile may be located.
|
static java.lang.String |
getEnvCatalogPath(java.lang.String fileName)
If there is a value set for the XBRLCATALOGPATH variable, this method
returns the path indicated by the user in a system variable called XBRLCATALOGPATH concatenated with
the name of the XBRL catalog file.
|
static java.lang.String |
getMyXBRLDocumentsFolder()
This method returns a directory of the form
In windows
C:\Users\{UserName}\Documents\My XBRL or C:\Users\{UserName}\Documents\Mis archivos XBRL in spanish.
|
static java.lang.String |
getUserDefaultTaxonomyPath()
The processor has a property called XBRL_BASE. that property can be set by the user during initialization of
the processor.
|
static java.lang.String |
getUserPropertiesFileName(java.lang.String propertiesFileName)
Prepares a file name in the user's home directory appending the
directory for Reporting Standard tools and the file name
received as a parameter.
|
static void |
setupGUI()
This method executes common tasks in setting up the GUI for all
tools.
|
static void |
updateAllProperityFilesToNewLocation(java.io.File from,
java.io.File to)
This method moves all properties files in the from directory to the to directory
It is used to help moving property files when a new version is released.
|
public static final java.lang.String RSHomeDir
public static final java.lang.String RSHomeCatalogDir
public static final java.lang.String RSEnvVarHomeDir
public static final java.lang.String RSEnvPropHomeDir
public static final java.lang.String RSEnvPropCatalogDir
public static java.lang.String shortDateDateFormat
The idea is to put it here now, make sure it is used elsewhere and then move it into a user configurable property.
public static java.lang.String longDateDateFormat
The idea is to put it here now, make sure it is used elsewhere and then move it into a user configurable property.
public static java.lang.String getUserPropertiesFileName(java.lang.String propertiesFileName)
Reporting Standard directory is always "ReportingStandardXBRLTools"
User path is calculated from readUserPath()
propertiesFileName
- String, the properties file namereadUserPath()
public static java.lang.String createRSPropertiesDir()
public static void updateAllProperityFilesToNewLocation(java.io.File from, java.io.File to)
It is used to help moving property files when a new version is released.
from
- the fromto
- the topublic static java.lang.String getCatalogPath(java.lang.String fileName)
fileName
- the file namepublic static java.lang.String getMyXBRLDocumentsFolder()
public static java.lang.String getEnvCatalogPath(java.lang.String fileName)
fileName
- the file namepublic static void setupGUI()
public static java.lang.String getUserDefaultTaxonomyPath()
If exist, the returned value is ${XBRLCATALOGPATH}/Other.
If it does not exist, the returned value is the path where the executable is running (user.dir) Note. the content of the $XBRLCATALOGPATH variable is converted to a URI. In case it cannot be converted to a URI then it is converted to a File and from the returned file into a URI. in case of any error then the content of the variable is used directly.
public static java.lang.String findUserFileName(java.lang.String fileName)
fileName
- the file nameCopyright 2006-2015 Reporting Standard S.L., C/ Torrecilla del Puerto 1, 28043, Madrid, Espaņa