Module: Calligraphy

Defined in:
lib/calligraphy.rb,
lib/calligraphy/get.rb,
lib/calligraphy/put.rb,
lib/calligraphy/copy.rb,
lib/calligraphy/lock.rb,
lib/calligraphy/move.rb,
lib/calligraphy/mkcol.rb,
lib/calligraphy/utils.rb,
lib/calligraphy/delete.rb,
lib/calligraphy/unlock.rb,
lib/calligraphy/version.rb,
lib/calligraphy/propfind.rb,
lib/calligraphy/proppatch.rb,
lib/calligraphy/web_dav_request.rb,
lib/calligraphy/resource/resource.rb,
lib/calligraphy/resource/file_resource.rb,
lib/generators/calligraphy/install_generator.rb

Defined Under Namespace

Modules: Generators, Rails, Utils, XML Classes: Copy, Delete, FileResource, Get, Lock, Mkcol, Move, Propfind, Proppatch, Put, Resource, Unlock, WebDavRequest

Constant Summary collapse

DAV_NS =

Constants used throughout Calligraphy.

'DAV:'
DAV_NO_LOCK_REGEX =
/DAV:no-lock/i
DAV_NOT_NO_LOCK_REGEX =
/Not\s+<DAV:no-lock>/i
ETAG_IF_REGEX =
/\[(.+?)\]/
INFINITY =
1.0 / 0.0
LOCK_TOKEN_ANGLE_REGEX =
/[<>]/
LOCK_TOKEN_REGEX =
/<(urn:uuid:.+?)>/
RESOURCE_REGEX =
/^<+(.+?)>\s/
TAGGED_LIST_REGEX =
/\)\s</
UNTAGGAGED_LIST_REGEX =
/\)\s\(/
VERSION =
'0.2.1'
@@allowed_http_methods =
%w(
  options get put delete copy move
  mkcol propfind proppatch lock unlock
)
@@digest_password_procedure =
Proc.new { |username| 'changeme!' }
@@enable_digest_authentication =
false
@@http_authentication_realm =
'Application'
@@lock_timeout_period =
86400
@@web_dav_actions =
i(
  options get put delete copy move
  mkcol propfind proppatch lock unlock
)

Class Method Summary collapse

Class Method Details

.configure {|_self| ... } ⇒ Object

Default way to set up Calligraphy. Run ‘rails generate calligraphy:install` to generate a fresh initializer with all configuration values.

Yields:

  • (_self)

Yield Parameters:

  • _self (Calligraphy)

    the object that the method was called on



75
76
77
# File 'lib/calligraphy.rb', line 75

def self.configure
  yield self
end