TBitConverter

FromBcd  
FromByte  
FromCurrency  
FromDouble  
FromExtended  
FromInteger  
FromLargeInt  
FromLongBool  
FromLongInt  
FromLongWord  
FromShortInt  
FromSingle  
FromSmallInt  
FromSqlTimeStamp  
FromSqlTimeStampOffset  
FromVariant  
FromWord  
FromWordBool

TBitConverter provides two main class functions:

  • From converts a value in a Delphi native type into an array of bytes.
  • InTo converts an array of bytes into a Delphi native type.

Data.DB.TBitConverter.FromCurrency

From RAD Studio API Documentation
 

FromCurrency From

Delphi

class procedure FromCurrency(Value: Currency; Buffer: TArray<Byte>);
C++

__classmethod void __fastcall FromCurrency(System::Currency Value, System::DynamicArray<System::Byte> Buffer);
>>>>>>> Delphi
class procedure From<T>(const Value: T; var B: TArray<Byte>; Offset: Integer = 0); static;

C++

void __fastcall TBitConverter::From(const T Value, System::DynamicArray<System::Byte> &B, int Offset)

ToInteger InTo

Data.DB.TBitConverter.ToIntegerFrom RAD Studio API Documentation

Delphi

class function ToInteger(Value: TArray<Byte>): Integer;

C++

__classmethod int __fastcall ToInteger(System::DynamicArray<System::Byte> Value);

System.Types.TBitConverter.InTo     From RAD Studio API Documentation

Delphi

class function InTo<T>(const B: TArray<Byte>; Offset: Integer = 0): T;

static;C++

__fastcall TBitConverter::InTo(const System::DynamicArray<System::Byte> B, int Offset)

<T>必须是明确的类型

Data := TBitConverter.InTo<double>(Buffer);

TBitConverter的更多相关文章

  1. System.Types.hpp(77): E2029 'TObject' must be a previously defined class or struct

    System.Types.hpp System.Types.hpp(77): E2029 'TObject' must be a previously defined class or struct ...

随机推荐

  1. UVA-1604 Cubic Eight-Puzzle (双向BFS+状态压缩+限制搜索层数)

    题目大意:立体的八数码问题,一次操作是滚动一次方块,问从初始状态到目标状态的最少滚动次数. 题目分析:这道题已知初始状态和目标状态,且又状态数目庞大,适宜用双向BFS.每个小方块有6种状态,整个大方格 ...

  2. HDU 1241 Oil Deposits bfs 难度:0

    http://acm.hdu.edu.cn/showproblem.php?pid=1241 对每个还未访问的点bfs,到达的点都标为一块,最后统计有多少块即可 #include <cstdio ...

  3. git一键提交修改文件

    git一键提交修改文件 首先安装git, 有git bash: 新建一个gitcmt文件,放置于与你的项目同级的目录里: 使用:打开git bash, 方法1. git pull\git status ...

  4. IE、Chrome、Firefox 三大浏览器对比

    1. 代理 IE 浏览器设置代理位置在: [Internet 选项]⇒ [连接]选项卡 ⇒ [局域网设置],如下: Chrome 的代理配置界面完全同 IE,只是你设置路径在: [设置]⇒ [高级]⇒ ...

  5. ballerina 学习二十五 项目docker 部署&& 运行

    ballerina 官方提供了docker 的runtime,还是比较方便的 基本项目创建 使用cli创建项目 按照提示操作就行 ballerina init -i 项目结构 添加了dockerfil ...

  6. 【转】MFC消息处理(一)

    原文网址:http://blog.csdn.net/hyhnoproblem/article/details/6182120 1.MFC窗口如何与AfxWndProc建立联系. 当一个新的CWnd派生 ...

  7. centos alias命令详解

    Alias命令 功能描述:我们在进行系统的管理工作一定会有一些我们经常固定使用,但又很长的命令.那我们可以给这些这一长串的命令起一个别名.之后还需要这一长串命令时就可以直接以别名来替代了.系统中已经有 ...

  8. application项目获取bean

    对于web项目,编程方式获取bean如下: WebApplicationContext wac = ContextLoader.getCurrentWebApplicationContext(); C ...

  9. 记录一次MyEclipse工程搭建的辛酸

    一个历史项目,使用的是Myeclipse6.5版本:这一天就砸在这个项目了. 调通web项目:内置的是tomcat插件,貌似和eclipse的server版的还不太一样. 长这个样子:

  10. oracle 归档日志总结

    Oracle 归档模式和非归档模式 归档模式和非归档模式 在DBA部署数据库之初,必须要做出的最重要决定之一就是选择归档模式(ARCHIVELOG)或者非 归档模式(NOARCHIVELOG )下运行 ...