API:EPrints/MetaField/Base64

From EPrints Documentation
Revision as of 17:00, 20 March 2023 by Pod2wiki (talk | contribs) (Created page with "<!-- Pod2Wiki=_preamble_ This page has been automatically generated from the EPrints 3.4 source. Any wiki changes made between the 'Pod2Wiki=*' and 'Edit below this comment'...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

EPrints 3 Reference: Directory Structure - Metadata Fields - Repository Configuration - XML Config Files - XML Export Format - EPrints data structure - Core API - Data Objects


API: Core API

Latest Source Code (3.4, 3.3) | Revision Log | Before editing this page please read Pod2Wiki


NAME

EPrints::MetaField::Base64 - Base 64 encoded data

User Comments


DESCRIPTION

Data encoded in base64. This may be small files (e.g. kilobytes) better save in the database rather than to the filesystem.

User Comments


INHERITANCE

EPrints::MetaField =over 4 EPrints::MetaField::Text =over 4 EPrints::MetaField::Longtext =over 4 EPrints/MetaField/Base64

User Comments


PROPERTIESTo be written

User Comments


METHODS

User Comments


form_value

$value = $field->form_value( $session, $object, [$prefix] )

Base64 encode the CGI parameter submitted within the form for this particular field. Assuming the from contained such an input field.

Returns a single scalar or array of base64 encoded values.

User Comments


to_sax

$xml = $field->to_sax( $value, %opts )

Print the field and value(s) as an XML representation of a base64 field.

User Comments


get_xml_schema_type

$type = $field->get_xml_schema_type

Gets the XML schema type for this base64 field.

Returns a string containing the type, dataset ID and and name of this field (e.g. base64_file_data).

User Comments


render_xml_schema_type

$type = $field->render_xml_schema_type

Produces an XML fragment this base64 field.

Returns a DOM for the following:

<xs:complexType name="base64_file_data">
  <xs:simpleContent>
    <xs:extension base="xs:base64Binary">
      <xs:attribute name="encoding">
        <xs:simpleType>
          <xs:restriction base="xs:string">
            <xs:enumeration value="base64" />
          </xs:restriction>
        </xs:simpleType>
      </xs:attribute>
    </xs:extension>
  </xs:simpleContent>
</xs:complexType>
 

E.g., <data encoding="base64">...</data>

User Comments


COPYRIGHT

© Copyright 2023 University of Southampton.

EPrints 3.4 is supplied by EPrints Services.

http://www.eprints.org/eprints-3.4/

LICENSE

This file is part of EPrints 3.4 http://www.eprints.org/.

EPrints 3.4 and this file are released under the terms of the GNU Lesser General Public License version 3 as published by the Free Software Foundation unless otherwise stated.

EPrints 3.4 is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with EPrints 3.4. If not, see http://www.gnu.org/licenses/.

User Comments