[ library(flexlm) | Reference Manual | Alphabetic Index ]

licence_checkout(+Feature, ++Policy, +Version, +Path, -Message, -Status)

Check out a licenced feature from FlexLM
Feature
String or atom
Policy
List of atoms
Version
String
Path
String, possibly empty
Message
Returns error/warning message, if any
Status
Returns one of the atoms ok, warning, error

Description

This maps directly to lp_checkout() of the FlexLM simple API.
Feature
is the name of the feature to be checked out, passed directly to FlexLM.
Policy
is a list of atoms, containing one of and possibly one or more of Note that LM_MANUAL_HEARTBEAT will always be set. An empty list defaults to LM_RESTRICTIVE|LM_MANUAL_HEARTBEAT.
Version
is a version string, passed directly to FlexLM.
Path
is the name of the licence file. If the empty string is given, it defaults to "licence.dat" in the ECLiPSe top-level installation directory. The lp_handle is not visible and stored internally by ECLiPSe. The feature name is used to identify the checked out licence on the Eclipse level.
Status
will be bound to one of the atoms ok,warning, error
Message
will be bound to an error or warning message string in case the Status is not ok
Multiple checkouts of the same feature are allowed, but only if they are for the same Policy and Version.

Fail Conditions

None

Examples

    ?- sepia_kernel:licence_checkout(swapper, [restrictive], "2.0", "", Msg, Status),
    	( Status = error ->
	    writeln(error, Msg),
	    abort
	;
	    writeln(warning_output, Msg)
	;
	    true
	).
    

See Also

get_flag / 2, licence_heartbeat / 4, licence_checkin / 1, licence_held / 1