xltIDexample: xltIDexample

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/xltIDexample.R

Description

xltIDexample returns synthetic, valid 128-bit numbers in hexadecimal notation (hexlets) in different common formats. The synthetic examples are easy to distinguish from "real" IDs to prevent their accidental use in an application.

Usage

1
xltIDexample(sel = 1:5)

Arguments

sel

(numeric, logical, or character) a subsetting vector

Details

The function stores five artificial sample IDs. Input is a subsetting vector that specifies which IDs to return. More than five IDs can be requested by applying the usual subsetting rules. The IDs can be converted to the exact same QQIDs provided by QQIDexample(). The formats available are "md5": 32 hex numerals; "hex": 32 hex numerals with "0x" prefix; "UUID": Universally Unique Identifier format; "IPv6": IPv6 formatted address; "hEx": 32 hex numerals with mixed case.

Value

(character) a named vector of formatted hexlets.

Author(s)

Boris Steipe (aut)

(c) 2019 Boris Steipe, licensed under MIT (see file LICENSE in this package).

See Also

QQIDexample() Returns five QQIDs

Examples

1
2
3
4
5
xltIDexample()                                  # the five stored hexlets
xltIDexample(2:3)                               # a hex number and a UUID
xltIDexample(c(TRUE, FALSE))                    # vector recycling
xltIDexample(sample(1:5, 17, replace = TRUE))   # seventeen in random order
xltIDexample("UUID") == qq2uu(QQIDexample(3))   # TRUE (correct conversion)

qqid documentation built on May 2, 2019, 12:19 p.m.