Namespace: Consultingwerk.Util
Class 
CodepageHelper Copy to Clipboard
Parent classes:
Inherits: Progress.Lang.Object

File:CodepageHelper
Purpose:Provides helper methods for code page operations or
validation
Author(s):Mike Fechner / Consultingwerk Ltd.
Created:Mon Mar 17 07:55:52 CET 2014



Top Method Summary
Options Name Purpose
+ LOGICAL CompliesWithCodepage (ISerializable, character) Verifies if a given ISerializable instance complies with a target code page
+ LOGICAL CompliesWithCodepage (handle, character) Verifies if a given ProDataset or Temp-Table complies with a target code page
+ LOGICAL CompliesWithCodepage (longchar, character) Verifies if a given CHARACTER or LONGCHAR value complies with a target code page


Method Detail
Top

PUBLIC LOGICAL CompliesWithCodepage (ISerializable, character)

Purpose: Verifies if a given ISerializable instance complies with a target
code page
Notes: Writes the ISerializable to an UTF-8 LONGCHAR and verifies code page
compliance of that LONGCHAR

Parameters:
poData Consultingwerk.ISerializable
The reference to the ISerializable instance to test
pcTargetCodepage CHARACTER
The target code page to verify against
Returns LOGICAL
Logical value indicating of the value complies with the target codepage
Top

PUBLIC LOGICAL CompliesWithCodepage (handle, character)

Purpose: Verifies if a given ProDataset or Temp-Table complies with a target
code page
Notes: Saves the temp-table as XML to an UTF-8 LONGCHAR and verifies code page
compliance of that LONGCHAR

Parameters:
phData HANDLE
The Handle of the ProDataset or Temp-Table to test
pcTargetCodepage CHARACTER
The target code page to verify against
Returns LOGICAL
Logical value indicating of the value complies with the target codepage
Top

PUBLIC LOGICAL CompliesWithCodepage (longchar, character)

Purpose: Verifies if a given CHARACTER or LONGCHAR value complies with a
target code page
Notes: Tries to assign the value to a LONGCHAR fixed to the target codepage
and handles error ** Unable to update Field. (142)

Parameters:
plcValue LONGCHAR
The LONGCHAR or CHARACTER value to test
pcTargetCodepage CHARACTER
The target code page to verify against
Returns LOGICAL
Logical value indicating of the value complies with the target codepage


©2006-2016 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       26.08.2016 08:46:17