Giter VIP home page Giter VIP logo

simplebaselib4pascal's Introduction

SimpleBaseLib4Pascal License

SimpleBaseLib4Pascal as the name implies is a simple to use Base Encoding Package for Delphi/FreePascal Compilers that provides at the moment support for encoding and decoding various bases such as Base16, Base32 (various variants), Base58 (various variants) and Base64 (various variants) and Base85 (various variants).

Build Status Build Status

Supported Encodings:

Base32: RFC 4648, Crockford and Extended Hex (BASE32-HEX) alphabets with Crockford character substitution 
and custom flavors.

Base58: Bitcoin, Ripple and Flickr alphabets and custom flavors.

Base64: Default, DefaultNoPadding, UrlEncoding, XmlEncoding, RegExEncoding and FileEncoding alphabets 
(and any custom alphabet you might have)

Base85: Ascii85 (Original), Z85 and custom flavors.

Base16: An experimental hexadecimal encoder/decoder.

Supported Compilers

FreePascal 3.0.0 and Above.

Delphi 2010 and Above.

Installing the Library.

Method One:

Use the Provided Packages in the "Packages" Folder.

Method Two:

Add the Library Path and Sub Path to your Project Search Path.

Usage Examples.

Check the "SimpleBaseLib.Benchmark" folder and the Unit Tests.

Unit Tests.

To Run Unit Tests,

For FPC 3.0.0 and above

Simply compile and run "SimpleBaseLib.Tests" project in "FreePascal.Tests" Folder.

For Delphi 2010 and above

Method One (Using DUnit Test Runner)

 To Build and Run the Unit Tests For Delphi 10 Tokyo (should be similar for 
 other versions)

1). Open Project Options of Unit Test (SimpleBaseLib.Tests) in "Delphi.Tests" Folder.

2). Change Target to All Configurations (Or "Base" In Older Delphi Versions.)

3). In Output directory add ".\$(Platform)\$(Config)" without the quotes.

4). In Search path add "$(BDS)\Source\DUnit\src" without the quotes.

5). In Unit output directory add "." without the quotes.

6). In Unit scope names (If Available), Delete "DUnitX" from the List.

Press Ok and save, then build and run.

Method Two (Using TestInsight) (Preferred).

1). Download and Install TestInsight.

2). Open Project Options of Unit Test (SimpleBaseLib.Tests.TestInsight) in "Delphi.Tests" 
    Folder. 

3). Change Target to All Configurations (Or "Base" In Older Delphi Versions.)

4). In Unit scope names (If Available), Delete "DUnitX" from the List.

5). To Use TestInsight, right-click on the project, then select 
	"Enable for TestInsight" or "TestInsight Project".
    Save Project then Build and Run Test Project through TestInsight. 

License

This "Software" is Licensed Under MIT License (MIT) .

Tip Jar

  • ๐Ÿ’ต Bitcoin: 1MhFfW7tDuEHQSgie65uJcAfJgCNchGeKf
  • ๐Ÿ’ถ Ethereum: 0x6c1DC21aeC49A822A4f1E3bf07c623C2C1978a98
  • ๐Ÿ’ท Pascalcoin: 345367-40

simplebaselib4pascal's People

Contributors

xor-el avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

simplebaselib4pascal's Issues

Additional data types support

IBaseXX = interface(IInterface)
    function Encode(const bytes: TSimpleBaseLibByteArray; padding: Boolean): String;
    function Decode(const text: String): TSimpleBaseLibByteArray;
end;

Is possible to extend interfaces to Encode/Decode additional data types like Pointer?

Eg.
function Encode(const memory : Pointer; size : Integer; padding : Boolean) : string;

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.