R: Get or set entries in the pattern dictionary

ore.dict {ore} | R Documentation

## Get or set entries in the pattern dictionary

### Description

This function allows the user to get or set entries in the pattern dictionary, a library of regular expressions whose elements can be referred to by name in `ore`, and therefore easily reused.

### Usage

    ore.dict(..., enclos = parent.frame())

### Arguments

`...` | One or more strings or dictionary keys. Unnamed, literal strings will be returned unmodified, named strings will be added to the dictionary, and unquoted names will be resolved using the dictionary.
`enclos` | Enclosure for resolving names not present in the dictionary. Passed to `eval`.

### Value

If no arguments are provided, the whole dictionary is returned. Otherwise the return value is a (possibly named) character vector of resolved strings.

### See Also

`ore`, which passes its arguments through this function

### Examples

    # Literal strings are returned as-is
    ore.dict("protocol")

    # Named arguments are added to the dictionary
    ore.dict(protocol="\\w+://")

    # ... and can be retrieved by name
    ore.dict(protocol)

[Package ore version 1.6.0 Index]