# Unit synaip

Description | uses | Classes, Interfaces, Objects and Records | Functions and Procedures | Types | Constants | Variables

## Description

IP adress support procedures and functions

## uses

- SysUtils
- SynaUtil

## Overview

### Functions and Procedures

`function IsIP(const Value: string): Boolean;`
`function IsIP6(const Value: string): Boolean;`
`function IPToID(Host: string): Ansistring;`
`function StrToIp6(value: string): TIp6Bytes;`
`function Ip6ToStr(value: TIp6Bytes): string;`
`function StrToIp(value: string): integer;`
`function IpToStr(value: integer): string;`
`function ReverseIP(Value: AnsiString): AnsiString;`
`function ReverseIP6(Value: AnsiString): AnsiString;`
`function ExpandIP6(Value: AnsiString): AnsiString;`

### Types

`TIp6Bytes = array [0..15] of Byte;`
`TIp6Words = array [0..7] of Word;`

## Description

### Functions and Procedures

`function IsIP(const Value: string): Boolean;`

Returns `True`, if "Value" is a valid IPv4 address. Cannot be a symbolic Name!

`function IsIP6(const Value: string): Boolean;`

Returns `True`, if "Value" is a valid IPv6 address. Cannot be a symbolic Name!

`function IPToID(Host: string): Ansistring;`

Returns a string with the "Host" ip address converted to binary form.

`function StrToIp6(value: string): TIp6Bytes;`

Convert IPv6 address from their string form to binary byte array.

`function Ip6ToStr(value: TIp6Bytes): string;`

Convert IPv6 address from binary byte array to string form.

`function StrToIp(value: string): integer;`

Convert IPv4 address from their string form to binary.

`function IpToStr(value: integer): string;`

Convert IPv4 address from binary to string form.

`function ReverseIP(Value: AnsiString): AnsiString;`

Convert IPv4 address to reverse form.

`function ReverseIP6(Value: AnsiString): AnsiString;`

Convert IPv6 address to reverse form.

`function ExpandIP6(Value: AnsiString): AnsiString;`

Expand short form of IPv6 address to long form.

### Types

`TIp6Bytes = array [0..15] of Byte;`

binary form of IPv6 adress (for string conversion routines)

`TIp6Words = array [0..7] of Word;`

binary form of IPv6 adress (for string conversion routines)

Generated by PasDoc 0.9.0 on 2012-04-23 21:38:52