PHP Class MedraWebservice, ojs

Afficher le fichier Open project: pkp/ojs Class Usage Examples

Méthodes publiques

Свойство Type Description
$_auth HTTP authentication credentials.
$_endpoint The mEDRA web service endpoint.

Méthodes publiques

Méthode Description
__construct ( $endpoint, $login, $password ) Constructor
_doRequest ( $action, $arg, $attachment = null ) : boolean | string Do the actual web service request.
_escapeXmlEntities ( $string ) Escape XML entities.
_getContentId ( $prefix ) : string Create a globally unique MIME content ID.
_getMimePart ( $contentId, $content ) : string Create a mime part with the given content.
upload ( $xml ) mEDRA upload operation.
viewMetadata ( $doi ) mEDRA viewMetadata operation

Method Details

__construct() public méthode

Constructor
public __construct ( $endpoint, $login, $password )
$endpoint string The mEDRA web service endpoint.
$login string
$password string

_doRequest() public méthode

Do the actual web service request.
public _doRequest ( $action, $arg, $attachment = null ) : boolean | string
$action string
$arg string
$attachment array
Résultat boolean | string True for success, an error message otherwise.

_escapeXmlEntities() public méthode

Escape XML entities.
public _escapeXmlEntities ( $string )
$string string

_getContentId() public méthode

Create a globally unique MIME content ID.
public _getContentId ( $prefix ) : string
$prefix string
Résultat string

_getMimePart() public méthode

Create a mime part with the given content.
public _getMimePart ( $contentId, $content ) : string
$contentId string
$content string
Résultat string

upload() public méthode

mEDRA upload operation.
public upload ( $xml )
$xml

viewMetadata() public méthode

mEDRA viewMetadata operation
public viewMetadata ( $doi )

Property Details

$_auth public_oe property

HTTP authentication credentials.
public $_auth

$_endpoint public_oe property

The mEDRA web service endpoint.
public $_endpoint