npid

package
v1.2.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 23, 2025 License: MIT Imports: 4 Imported by: 1

Documentation

Overview

Package npid provides a ID generator based on machine network private IP and process ID.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(ip4 uint32, pid int, ip4Bits, pidBits int) int64

func New

func New(ip4Bits, pidBits int) int64

New returns a ID based on private IPv4 and process ID. The default ID format: +--------------------------------------------------+ | (64 - x - y) Bit Unused | x Bit IPv4 | y Bit PID | +--------------------------------------------------+

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL