WideStudio/MWT Class Reference

WideStudio/MWT Home
Up to


クラスの型

特にありません

メソッド関数仕様



WSGFgetUCS2 関数の説明

書式
WSCushort* WSGFgetUCS2(const char* text,long encoding)
機能
指定されたエンコーディングの文字列をUCS2に変換します。
処理
引数
(in)const char* text 変換したい文字列
(in)long encoding 変換したい文字列のエンコーディング

エンコーディングに指定できる値には、 WSCstring クラスのコンストラクタを参照ください。
返値
UCS2文字列
注意
処理後は返された領域を破棄してください。
サンプル
   // UCS2文字列を取得
   WSCushort* ucs2_str = WSGFgetUCS2("変換したい文字列",WS_EN_UTF8);
   //処理後は破棄
   delete ucs2_str;



replaceFile 関数の説明

書式
long WSGFreplaceFile(char* fname,void* data,long len,WSCbool same_save)
機能
ファイルの内容を置き換える関数です。
処理
引数
(in)char* fname 更新するファイルの名称
(in)void* data 更新内容
(in)long len 更新データのバイト数
(in)WSCbool same_save 内容が同じでも True=更新/False=更新しない

返値
WS_NO_ERR= 正常、それ以外はエラー。
注意
サンプル
   //ファイル abc の内容を、"abcdefg" で置き換え
   char* data = "abcdefg";
   long ret = WSGFreplaceFile("abc",data,strlen(data),True);



replaceTextFile 関数の説明

書式
long WSGFreplaceTextFile(char* fname,char* data,WSCbool same_save)
機能
ファイルの内容を置き換える関数です。
処理
引数
(in)char* fname 更新するファイルの名称
(in)char* data 更新内容
(in)WSCbool same_save 内容が同じでも True=更新/False=更新しない

返値
WS_NO_ERR= 正常、それ以外はエラー。
注意
サンプル
   //ファイル abc の内容を、"abcdefg" で置き換え
   char* data = "abcdefg";
   long ret = WSGFreplaceTextFile("abc",data,True);



WSGFgetDirName 関数の説明

書式
WSCstring WSGFgetDirName(char* path)
機能
path 名から、ファイル名称とディレクトリ名称に別け、 ディレクトリ名称を取得します。
処理
引数
(in)char* path パス名

返値
ディレクトリ名
注意
サンプル
   //パス名 /dir1/dir2/file のディレクトリ名部分(/dir1/dir2)を取得
   WSCstring dname = WSGFreplaceTextFile("/dir1/dir2/file");



WSGFgetFileName 関数の説明

書式
WSCstring WSGFgetFileName(char* path)
機能
path 名から、ファイル名称とディレクトリ名称に別け、 ファイル名称を取得します。
処理
引数
(in)char* path パス名

返値
ファイル名
注意
サンプル
   //パス名 /dir1/dir2/file のファイル名部分(file)を取得
   WSCstring dname = WSGFreplaceTextFile("/dir1/dir2/file");


Document Release 3.98

For Use with WideStudio/MWT Release 3.98, Summer 2008


WideStudio/MWT Home | Up to

Copyright(C) WideStudio/MWT Development Team, 1999-2008 Last modified: June 25, 2008