Skip to content
This repository has been archived by the owner on Aug 27, 2022. It is now read-only.

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
cgivre authored Nov 10, 2016
1 parent b414cf5 commit b540dad
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,27 @@
# Drill Network Functions
This library contains a collection of network-related functions for Apache Drill. It includes:

* `inet_aton(<IPv4>)`: This function converts an IPv4 address in dotted decimal notation into an integer. This is useful for sorting IP addresses, and reducing the amount of space that they take on disk.
* **`inet_aton(<IPv4>)`**: This function converts an IPv4 address in dotted decimal notation into an integer. This is useful for sorting IP addresses, and reducing the amount of space that they take on disk.

* `inet_ntoa(<int>)`: This function returns an IP in dotted decimal notation given its integer representation.
* **`inet_ntoa(<int>)`**: This function returns an IP in dotted decimal notation given its integer representation.

* `is_private_ip(<IPv4>)`: Returns true if the IP address is private.
* **`is_private_ip(<IPv4>)`**: Returns true if the IP address is private.

* `in_network( <IPv4>, <CIDR Block>)`: Retunrs true if the IPv4 address is in the CIDR Block
* **`in_network( <IPv4>, <CIDR Block>)`**: Retunrs true if the IPv4 address is in the CIDR Block

* `getAddressCount( <CIDR Block> )`: Returns the number of IP addresses in a given CIDR Block
* **`getAddressCount( <CIDR Block> )`**: Returns the number of IP addresses in a given CIDR Block

* `getBroadcastAddress( <CIDR Block> )`: Returns the broadcast address in dotted decimal notation from a given CIDR block.
* **`getBroadcastAddress( <CIDR Block> )`**: Returns the broadcast address in dotted decimal notation from a given CIDR block.

* `getNetmask( <CIDR Block> )`: Returns the netmask for a given CIDR Block
* **`getNetmask( <CIDR Block> )`**: Returns the netmask for a given CIDR Block

* `getLowAddress( <CIDR Block> )`: Returns the first IPv4 address in dotted decimal notation for a given CIDR Block
* **`getLowAddress( <CIDR Block> )`**: Returns the first IPv4 address in dotted decimal notation for a given CIDR Block

* `getHighAddress( <CIDR Block> )`: Returns the last IPv4 address in dotted decimal notation for a given CIDR Block
* **`getHighAddress( <CIDR Block> )`**: Returns the last IPv4 address in dotted decimal notation for a given CIDR Block

## Installing These Functions
This collection of functions does not have any dependencies that are not already included in Drill. You can build the functions from source by cloning this repository, navigating to the directory and typing:
`mvn clean package -DskipTests`.
Once you've done that, you'll find two `.jar` files in the `target/` folder. Copy both these files to `<drill path>/jars/3rdParty`.

Alternatively, you can download the jar files here: and copy them to `<drill path>/jars/3rdParty`.

0 comments on commit b540dad

Please sign in to comment.