-- I fails compilation saying "Attribute value must be Constant", on probing further found that we have pathSeparator in defined as
" public static final String pathSeparator = "" + pathSeparatorChar;" in File.java
and pathSeparatorChar resolves to fs.getPathSeparator() and method getPathSeparator()resolves to abstract char attribute of FileSystem.java
--During compile time we will not be able make out what is actual value for getPathSeparator() since its abstract and no concrete values can be deduced and during run-time this depends on underlying OS File System.
-- So Separator can't make out run-time dependent values and values has to be resolved at compile time only.
The text was updated successfully, but these errors were encountered:
Hi,
In Type conversion example we have following for Separator Annotation [http://owner.aeonbits.org/docs/type-conversion/]
@Separator(File.pathSeparator);
File[] path();
-- I fails compilation saying "Attribute value must be Constant", on probing further found that we have pathSeparator in defined as
" public static final String pathSeparator = "" + pathSeparatorChar;" in File.java
and pathSeparatorChar resolves to fs.getPathSeparator() and method getPathSeparator()resolves to abstract char attribute of FileSystem.java
--During compile time we will not be able make out what is actual value for getPathSeparator() since its abstract and no concrete values can be deduced and during run-time this depends on underlying OS File System.
-- So Separator can't make out run-time dependent values and values has to be resolved at compile time only.
The text was updated successfully, but these errors were encountered: