Module: Evvnt::PathHelpers

Included in:
Base
Defined in:
lib/evvnt/path_helpers.rb

Overview

Internal: Helper methods defining API paths for the defined resources

Constant Summary collapse

PARAM_REGEX =

A regular expression to check for params in a URL String.

%r{\:[^\/$]+}

Instance Method Summary collapse

Instance Method Details

#resource_nameObject

The name for this class’s corresponding resource on the API.



16
17
18
# File 'lib/evvnt/path_helpers.rb', line 16

def resource_name
  @resource_name || default_resource_name
end

#singular_resource?Boolean

Is this class defined as a singular resource?

Returns Boolean

Returns:

  • (Boolean)


11
12
13
# File 'lib/evvnt/path_helpers.rb', line 11

def singular_resource?
  @singular_resource == true
end