Package com.iizix.text
Class ValidationKStringInfoProviderHolder
java.lang.Object
com.iizix.text.ValidationKStringInfoProviderHolder
- All Implemented Interfaces:
- IKStringInfoProvider,- IKStringInfoProviderHolder
public class ValidationKStringInfoProviderHolder extends Object implements IKStringInfoProvider, IKStringInfoProviderHolder
Very simple adapter to provide information required by KString's when resolving KString's for validation. Image resolving and so on is not supported. Installing fonts is not supported either.
- Author:
- Christopher Mindus
- Constructor SummaryConstructorsConstructorDescription- ValidationKStringInfoProviderHolder- (GProp<?> anyProp, String targetLanguageCode) Constructor.
- Method SummaryModifier and TypeMethodDescription- booleanGets the flag for adding the reference string in an attribute when editing the KString.- double- getDPR()Gets the device pixel ratio.Gets the HTTP Server string prefix including port.- getImageTarget- (String ref) Gets the image reference.Retrieves the KStringInfoProvider.- GProp<?>Gets the property used for references look-up's.Gets the base reference name for the resource, typically an image, for the Server or the Designer.Gets the language code to use.- boolean- installFont- (String fontFamily) Installs the font families as specified by the font family.- boolean- installFonts- (String fontFamilies) Installs the font families as specified by the font family.- boolean- installFonts- (List<FontFiles> fontList) Installs the font face as specified by the- FontFilesinstance for the Client Session.- booleanFlag indicating the "real" resolved string should be returned.
- Constructor Details- ValidationKStringInfoProviderHolderConstructor.- Parameters:
- anyProp- Any property for resolving references.
- targetLanguageCode- Target language code when working with multiple text files.
 
 
- Method Details- getKStringInfoProviderRetrieves the KStringInfoProvider.- Specified by:
- getKStringInfoProviderin interface- IKStringInfoProviderHolder
- Returns:
- This instance.
 
- getHTTPServerGets the HTTP Server string prefix including port.- Specified by:
- getHTTPServerin interface- IKStringInfoProvider
- Returns:
- The "http://localhost".
 
- getImageTargetGets the image reference.- Specified by:
- getImageTargetin interface- IKStringInfoProvider
- Parameters:
- ref- The image definition reference string.
- Returns:
- The image found, or null if not found.
 
- doAddReferencepublic boolean doAddReference()Gets the flag for adding the reference string in an attribute when editing the KString.- Specified by:
- doAddReferencein interface- IKStringInfoProvider
- Returns:
- References in attributes should not be added, hence falseis returned.
 
- shouldResolvepublic boolean shouldResolve()Flag indicating the "real" resolved string should be returned. This value is true for the runtime client when in "real run mode".- Specified by:
- shouldResolvein interface- IKStringInfoProvider
- Returns:
- Always trueas KString's should resolve.
 
- getResolveReferencePropertyGets the property used for references look-up's.- Specified by:
- getResolveReferencePropertyin interface- IKStringInfoProvider
- Returns:
- Any property in the tree.
 
- getDPRpublic double getDPR()Gets the device pixel ratio.- Specified by:
- getDPRin interface- IKStringInfoProvider
- Returns:
- The device pixel ratio = 1.0d.
 
- getTargetLanguageCodeGets the language code to use.- Specified by:
- getTargetLanguageCodein interface- IKStringInfoProvider
- Returns:
- The language code, or null for default.
 
- getResourcePrefixGets the base reference name for the resource, typically an image, for the Server or the Designer. This reference is "/$" (the default in this interface) for the Designer, but should be "/$APPID/" for the Server, where APPID is the application being run by the client. The Server must therefore implement this method and return that string instead.- Specified by:
- getResourcePrefixin interface- IKStringInfoProvider
- Returns:
- Always "/$".
 
- installFontInstalls the font families as specified by the font family.- Specified by:
- installFontin interface- IKStringInfoProvider
- Parameters:
- fontFamily- The font family or families.
- Returns:
- Always falseas fonts are not supported.
 
- installFontsInstalls the font families as specified by the font family.- Specified by:
- installFontsin interface- IKStringInfoProvider
- Parameters:
- fontFamilies- The font family or families, comma separated.
- Returns:
- Always falseas fonts are not supported.
 
- installFontsInstalls the font face as specified by the- FontFilesinstance for the Client Session. Once installed, the font family can be used.- Specified by:
- installFontsin interface- IKStringInfoProvider
- Parameters:
- fontList- The list of font files to install.
- Returns:
- Always falseas fonts are not supported.