Liking cljdoc? Tell your friends :D

clj-jargon.init


anonymous-user-accountclj

(anonymous-user-account cfg)
source

clean-returnclj

(clean-return cm retval)
source

create-context-map-or-delayclj

(create-context-map-or-delay cfg client-user lazy?)

Creates a context map or a delay for one, depending whether lazy? is true

Creates a context map or a delay for one, depending whether lazy? is true
sourceraw docstring

create-jargon-context-mapclj

(create-jargon-context-map cfg client-user)

Creates a map containing instances of commonly used Jargon objects.

Throws: org.irods.jargon.core.exception.JargonException - This is thrown when if fails to connect to iRODS

Creates a map containing instances of commonly used Jargon objects.

Throws:
  org.irods.jargon.core.exception.JargonException - This is thrown when if fails to connect to iRODS
sourceraw docstring

curr-with-jargon-indexclj

source

default-proxy-ctorclj

This is the default constructor for creating an iRODS proxy.

This is the default constructor for creating an iRODS proxy.
sourceraw docstring

dirty-returnclj

(dirty-return retval)
source

initclj

(init host
      port
      user
      pass
      home
      zone
      res
      &
      {:keys [max-retries retry-sleep use-trash proxy-ctor]
       :or {max-retries 0
            retry-sleep 0
            use-trash false
            proxy-ctor default-proxy-ctor}})

Creates the iRODS configuration map.

Parameters: host - The IP address or FQDN of the iRODS server that will be used. port - The IP port the iRODS server listens to. username - The iRODS user name of the account that will be used while connected to iRODS. password - The password of user. home - The path to the user's home collection. zone - The zone to use defaultResource - The default resource to use. max-retries - The number of times to retry connecting to the server. This defaults to 0. retry-sleep - The number of milliseconds to wait between connection retries. This defaults to 0. use-trash - Indicates whether or to put deleted entries in the trash. This defaults to false. proxy-ctor - This is the constructor to use for creating the iRODS proxy. It takes no arguments, and the object its creates must implement have the following methods. ((close [_]) (^IRODSAccessObjectFactory getIRODSAccessObjectFactory [_]) (^IRODSFileFactory getIRODSFileFactory [_ ^IRODSAccount acnt])) These must be sematically equivalent to the corresponding methods in org.irods.jargon.core.pub.IRODSFileSystem. This argument defaults to default-proxy-ctor.

Returns: A map is returned with the provided parameters names and values forming the key-value pairs.

Creates the iRODS configuration map.

Parameters:
  host - The IP address or FQDN of the iRODS server that will be used.
  port - The IP port the iRODS server listens to.
  username - The iRODS user name of the account that will be used while
    connected to iRODS.
  password - The password of user.
  home - The path to the user's home collection.
  zone - The zone to use
  defaultResource - The default resource to use.
  max-retries - The number of times to retry connecting to the server.  This
    defaults to 0.
  retry-sleep - The number of milliseconds to wait between connection
    retries.  This defaults to 0.
  use-trash - Indicates whether or to put deleted entries in the trash.
    This defaults to false.
  proxy-ctor - This is the constructor to use for creating the iRODS proxy.
    It takes no arguments, and the object its creates must implement have
    the following methods.
    ((close [_])
     (^IRODSAccessObjectFactory getIRODSAccessObjectFactory [_])
     (^IRODSFileFactory getIRODSFileFactory [_ ^IRODSAccount acnt]))
    These must be sematically equivalent to the corresponding methods in
    org.irods.jargon.core.pub.IRODSFileSystem.  This argument defaults to
    default-proxy-ctor.

Returns:
  A map is returned with the provided parameters names and values forming
  the key-value pairs.
sourceraw docstring

log-stack-tracecljmacro

(log-stack-trace msg)
source

override-user-accountclj

(override-user-account cfg user pass)
source

proxy-input-streamclj

(proxy-input-stream cm istream)
source

proxy-input-stream-returnclj

(proxy-input-stream-return cm retval)
source

with-jargoncljmacro

(with-jargon cfg & params)

An iRODS connection is opened, binding the connection's context to the symbolic cm-sym value. Next it evaluates the body expressions. Finally, it closes the iRODS connection*. The body expressions should use the value of cm-sym to access the iRODS context.

Calling: (with-jargon cfg [cm-sym] body) (with-jargon cfg :opt-k opt-v ... [cm-sym] body)

Parameters: cfg - The Jargon configuration used to connect to iRODS. [cm-sym] - Holds the name of the binding to the iRODS context map used by the body expressions. body - Zero or more expressions to be evaluated while an iRODS connection is open.

Options: :auto-close - true if the connection should be closed automatically (default: true) :client-user - the user to operate as inside of iRODS (default: (:username cfg)) :lazy - true if the cm-sym should be a delay to be dereferenced as needed (default: false)

Returns: It returns the result from evaluating the last expression in the body.*

Throws: org.irods.jargon.core.exception.JargonException - This is thrown when if fails to connect to iRODS.

Example: (def config (init ...))

(with-jargon config [ctx] (list-all ctx "/zone/home/user/"))

  • If an IRODSFileInputStream is the result of the last body expression, the iRODS connection is not closed. Instead, a special InputStream is returned that when closed, closes the iRODS connection as well. If the auto-close option is set to false (it's set to true by default) then the connection is not closed automatically. In that case, the caller must take steps to ensure that the connection will be closed (for example, by including a proxy input stream somewhere in the result and calling the close method on that proxy input stream later).
An iRODS connection is opened, binding the connection's context to the symbolic cm-sym value.
Next it evaluates the body expressions. Finally, it closes the iRODS connection*. The body
expressions should use the value of cm-sym to access the iRODS context.

Calling:
(with-jargon cfg [cm-sym] body)
(with-jargon cfg :opt-k opt-v ... [cm-sym] body)

Parameters:
  cfg      - The Jargon configuration used to connect to iRODS.
  [cm-sym] - Holds the name of the binding to the iRODS context map used by the body expressions.
  body     - Zero or more expressions to be evaluated while an iRODS connection is open.

Options:
  :auto-close  - true if the connection should be closed automatically (default: true)
  :client-user - the user to operate as inside of iRODS (default: (:username cfg))
  :lazy        - true if the cm-sym should be a delay to be dereferenced as needed (default: false)

Returns:
  It returns the result from evaluating the last expression in the body.*

 Throws:
   org.irods.jargon.core.exception.JargonException - This is thrown when if fails to connect to
                                                     iRODS.

 Example:
   (def config (init ...))

   (with-jargon config [ctx]
     (list-all ctx "/zone/home/user/"))

* If an IRODSFileInputStream is the result of the last body expression, the iRODS connection is
  not closed. Instead, a special InputStream is returned that when closed, closes the iRODS
  connection as well. If the auto-close option is set to false (it's set to true by default)
  then the connection is not closed automatically. In that case, the caller must take steps to
  ensure that the connection will be closed (for example, by including a proxy input stream
  somewhere in the result and calling the close method on that proxy input stream later).
sourceraw docstring

with-jargon-indexclj

source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close