ISO/IEC 21000-10:2006/Amd 1:2006
(Amendment)Information technology — Multimedia framework (MPEG-21) — Part 10: Digital Item Processing — Amendment 1: Additional C++ bindings
Information technology — Multimedia framework (MPEG-21) — Part 10: Digital Item Processing — Amendment 1: Additional C++ bindings
Technologies de l'information — Cadre multimédia (MPEG-21) — Partie 10: Traitement d'élément numérique — Amendement 1: Liaisons C++ additionnelles
General Information
Relations
Standards Content (Sample)
INTERNATIONAL ISO/IEC
STANDARD 21000-10
First edition
2006-01-01
AMENDMENT 1
2006-12-15
Information technology —
Multimedia framework (MPEG-21) —
Part 10:
Digital Item Processing
AMENDMENT 1: Additional C++ bindings
Technologies de l'information — Cadre multimédia (MPEG-21) —
Partie 10: Traitement d'élément numérique
AMENDEMENT 1: Liaisons C++ additionnelles
Reference number
ISO/IEC 21000-10:2006/Amd.1:2006(E)
©
ISO/IEC 2006
---------------------- Page: 1 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
PDF disclaimer
This PDF file may contain embedded typefaces. In accordance with Adobe's licensing policy, this file may be printed or viewed but
shall not be edited unless the typefaces which are embedded are licensed to and installed on the computer performing the editing. In
downloading this file, parties accept therein the responsibility of not infringing Adobe's licensing policy. The ISO Central Secretariat
accepts no liability in this area.
Adobe is a trademark of Adobe Systems Incorporated.
Details of the software products used to create this PDF file can be found in the General Info relative to the file; the PDF-creation
parameters were optimized for printing. Every care has been taken to ensure that the file is suitable for use by ISO member bodies. In
the unlikely event that a problem relating to it is found, please inform the Central Secretariat at the address given below.
© ISO/IEC 2006
All rights reserved. Unless otherwise specified, no part of this publication may be reproduced or utilized in any form or by any means,
electronic or mechanical, including photocopying and microfilm, without permission in writing from either ISO at the address below or
ISO's member body in the country of the requester.
ISO copyright office
Case postale 56 • CH-1211 Geneva 20
Tel. + 41 22 749 01 11
Fax + 41 22 749 09 47
E-mail copyright@iso.org
Web www.iso.org
Published in Switzerland
ii © ISO/IEC 2006 – All rights reserved
---------------------- Page: 2 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical
Commission) form the specialized system for worldwide standardization. National bodies that are members of
ISO or IEC participate in the development of International Standards through technical committees
established by the respective organization to deal with particular fields of technical activity. ISO and IEC
technical committees collaborate in fields of mutual interest. Other international organizations, governmental
and non-governmental, in liaison with ISO and IEC, also take part in the work. In the field of information
technology, ISO and IEC have established a joint technical committee, ISO/IEC JTC 1.
International Standards are drafted in accordance with the rules given in the ISO/IEC Directives, Part 2.
The main task of the joint technical committee is to prepare International Standards. Draft International
Standards adopted by the joint technical committee are circulated to national bodies for voting. Publication as
an International Standard requires approval by at least 75 % of the national bodies casting a vote.
Attention is drawn to the possibility that some of the elements of this document may be the subject of patent
rights. ISO and IEC shall not be held responsible for identifying any or all such patent rights.
Amendment 1 to ISO/IEC 21000-10:2006 was prepared by Joint Technical Committee ISO/IEC JTC 1,
Information technology, Subcommittee SC 29, Coding of audio, picture, multimedia and hypermedia
information.
This Amendment defines normative C++ bindings for Digital Item Base Operations, informative security and
platform dependence considerations, an informative example of a safe DIP profile and an entry to be
appended to the Bibliography.
© ISO/IEC 2006 – All rights reserved iii
---------------------- Page: 3 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
Information technology — Multimedia framework (MPEG-21) —
Part 10:
Digital Item Processing
AMENDMENT 1: Additional C++ bindings
In Clause 1, Scope, second paragraph, replace the text:
three normative annexes
with:
four normative annexes
In Clause 1, Scope, add at the end:
⎯ C++ bindings for Digital Item Base Operations:
Annex E specifies the C++ bindings for the Digital Item Base Operations described in 5.4.
In Clause 2, Normative references, insert the following normative reference before the reference to
ISO/IEC 16262:2002:
ISO/IEC 14882:2003, Programming languages — C++
Add a new subclause 5.6:
5.6 Security and platform dependence considerations (informative)
5.6.1 Security considerations
5.6.1.1 Execute DIBO
The use of the DIP.execute DIBO can potentially result in security issues, because the DIBO provides means
to execute arbitrary code.
5.6.1.2 C++ bindings
The use of the C++ DIBO bindings can potentially result in security issues.
5.6.1.3 DOM Load and Save
The DOM Load and Save API exposes potential security issues, because they provide access to the file
system.
© ISO/IEC 2006 – All rights reserved 1
---------------------- Page: 4 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
5.6.2 Platform dependence considerations
5.6.2.1 Execute DIBO
The use of the DIP.execute DIBO can result in the use of platform dependent code. It is possible to avoid
those issues by creating a profile removing DIP.execute. This can be done using profiles as demonstrated in
subclause Annex I.8.
5.6.2.2 C++ bindings
The use of the C++ DIBO bindings will result in the use of platform dependent code. It is possible to avoid
those issues by creating a profile removing the C++ bindings. This can be done using profiles as
demonstrated in subclause Annex I.8.
Adjust numbering clauses:
"5.6 Digital Item eXtension Operations" numbering change to "5.7 Digital Item eXtension Operations"
numbering.
And change following (sub)clauses numbering accordingly.
Add a new Annex E:
Annex E
(normative)
C++ bindings for Digital Item Base Operations
E.1 Introduction
C++ bindings for DIBOs are specified so that C++ executables can interact with the DIP environment. The
way in which C++ executables are executed and the reference to the bindings are obtained, is done in an
implementation specific way.
E.2 C++ data type bindings for DIML object types
E.2.1 DIPError
See 5.4.3.2
2 © ISO/IEC 2006 – All rights reserved
---------------------- Page: 5 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
#ifndef DIPERROR_H
#define DIPERROR_H
/**
* C++ interface for the DIPError.
*/
class DIPError {
public:
/**
* General DIP error not covered by other defined error codes.
* The value of this property is 1.
*/
static const int GENERAL_EXCEPTION;
/**
* A parameter provided to a DIBO or other DIP function is invalid.
* The value of this property is 2.
*/
static const int INVALID_PARAM;
/**
* Permission to execute this operation is unavailable in the host environment.
* The value of this property is 3.
*/
static const int INVALID_PERMISSION;
/**
* Something needed to complete the operation is not found.
* The value of this property is 4.
*/
static const int NOT_FOUND;
/**
* An error occurred during an attempt to adapt a resource.
* The value of this property is 5.
*/
static const int ADAPTATION_FAILED;
/**
* An error occurred during an attempt to play.
* The value of this property is 6.
*/
static const int PLAYBACK_FAILED;
/**
* An error occurred during an attempt to execute.
* The value of this property is 7.
*/
static const int EXECUTE_FAILED;
/**
* An error occurred during an attempt to print.
* The value of this property is 8.
*/
static const int PRINT_FAILED;
/**
* Returns the code of an error caused by an exception.
* @return int value representing DIPErrorCode or other value specified in ISO/IEC
* 21000.
*/
virtual int getDIPErrorCode() const = 0;
};
#endif
© ISO/IEC 2006 – All rights reserved 3
---------------------- Page: 6 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
E.2.2 ObjectMap
See 5.4.3.3
#ifndef OBJECTMAP_H
#define OBJECTMAP_H
#include
/**
* C++ interface for the ObjectMap DIML Object Type.
*/
class ObjectMap {
public:
/**
* Returns a pointer to succeeding char pointers representing the
* Arguments Types of an argument list.
* @param index The index of the Argument list in the Object Map.
* @return array of char pointers or null pointers if no such index exists. The
* last element of the array must be a null pointer.
*/
virtual char** getArgumentList(int index) const throw (DIPError) = 0;
/**
* Returns the number of unique argument lists with arguments in a specific order.
* @return int value indicating the number of unique argument lists.
*/
virtual int getArgumentListCount() const = 0;
/**
* Returns the number of DIMs taking arguments of given Argument Types.
* @param argumentList An array of char pointers representing the Arguments names.
* The last element of this array shall be a null pointer.
* @return int value indicating the number of DIMs.
*/
virtual int getMethodCount(char** argumentList) const throw (DIPError) = 0;
/**
* Returns a pointer to a DOMElement representing Components containing the DIM
* declarations of DIMs taking arguments of given Argument Types.
* @param argumentList An array of char pointers representing the Arguments names.
The last element of this array shall be a null pointer.
* @return pointer to DOMElement.
*/
virtual DOMElement* getMethodWithArgs(char** argumentList) const
throw (DIPError)= 0;
/**
* Returns an array of pointers to DOMElements representing Components containing
* the DIM declaration of a DIM taking arguments of given Argument Types.
* @param argumentList An array of char pointers representing the Arguments names.
The last element of this array shall be a null pointer.
* @param index An int value indicating the index of the DIM in the list of DIMS
that accept the char pointers of the argumentList parameter as
parameters.
* @return array of pointers to DOMElements. The last element of this array shall
* be a null pointer.
*/
virtual DOMElement** getMethodsWithArgs(char** argumentList, int index) const
throw (DIPError)= 0;
/**
* Returns a DID object corresponding to the given Object Type and the index.
* @param objectType A char pointer containing the Object Type of the wanted DID
object.
* @param index The index in the array to DID objects corresponding
to the Object Type.
4 © ISO/IEC 2006 – All rights reserved
---------------------- Page: 7 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
* @return pointer to DOMElement or null pointer if no such DID object exists.
*/
virtual DOMElement* getObjectOfType(char* objectType, int index) const
throw (DIPError)= 0;
/**
* Returns an array of DID objects corresponding to the given Object Type.
* @param objectType A char pointer containing the Object Type of the wanted DID
objects.
* @return array of pointers to DOMElements. The last element of the array must
* be a null pointer.
*/
virtual DOMElement** getObjectsOfType(char* objectType) const
throw (DIPError) = 0;
/**
* Returns the number of objects corresponding to a certain Object Type.
* @param objectTypeName A char pointer containing the name of the Object Type in
the Object Map.
* @return int value representing the number of objects.
*/
virtual int getObjectsOfTypeCount(char* objectTypeName) const
throw (DIPError) = 0;
/**
* Returns the number of Object Types defined in the Object Map.
* @return int value representing the number of Object Types.
*/
virtual int getObjectTypeCount() const = 0;
/**
* Returns a char pointer representing the Object Type name.
* @param index The index of the Object Type in the Object Map.
* @return char pointer or null pointer if no such index exists.
*/
virtual char* getObjectTypeName(int index) const throw (DIPError) = 0;
};
#endif
E.2.3 PlayStatus
See 5.4.3.4
#ifndef PLAYSTATUS_H
#define PLAYSTATUS_H
/**
* C++ interface for the PlayStatus DIML Object Type.
*/
class PlayStatus {
public:
/**
* Indicates that the associated resource is not currently playing.
* The value of this property is 0.
*/
static const int RELEASED;
/**
* Indicates that the associated resource is currently playing. Time based state
* information related to playing the resource, if relevant, is paused for a
* STATICPLAY resource.
© ISO/IEC 2006 – All rights reserved 5
---------------------- Page: 8 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
* The value of this property is 1.
*/
static const int STATICPLAY;
/**
* Indicates that the associated resource is currently playing. Time based state
* information related to playing the resource, if relevant, is advancing for a
* TIMEPLAY resource.
* The value of this property is 2.
*/
static const int TIMEPLAY;
/**
* Returns the current status of a played instance of a resource associated with
* this PlayStatus object.
* @return int value representing the current status.
*/
virtual int getStatus() const = 0;
};
#endif
E.3 C++ DIBO factory interface
This subclause specifies the C++ interface for the C++ DIBO factory. An MPEG-21 environment providing
C++ bindings to DIBOs shall provide an implementation of CppDIBOFactory.
The C++ DIBO factory is used in a C++ executable to obtain an instance of an object that implements the C++
binding for a DIBO. The interface of a C++ DIBO factory is defined below.
#ifndef CPPDIBOFACTORY_H
#define CPPDIBOFACTORY_H
#include "DIPError.h"
/**
* CppDIBOFactory interface is used to create new C++ DIBO classes.
*/
class CppDIBOFactory {
public:
/**
* Returns the implementation for the given DIML object interface.
* defining the set of C++ DIBO interfaces bound to the required DIBO. This method
* is implemented by the C++ DIBO implementation provider.
* @param objectName A char pointer containing the name of the DIML object for
* which the implementation is requested.
* @return void pointer representing the implementation for the given DIML object
* interface.
*/
virtual void* getCppDIBOObject(char* objectName) const throw (DIPError) = 0;
};
#endif
E.4 C++ global environment interface
A reference to the global environment (i.e., GlobalEnv object) should be provided to a C++ executable,
enabling access to the DIP environment in the C++ executables.
6 © ISO/IEC 2006 – All rights reserved
---------------------- Page: 9 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
#ifndef GLOBALENV_H
#define GLOBALENV_H
#include
#include "CppDIBOFactory.h"
/**
* C++ interface defining a mechanism for C++ executables to query the platform for
* environment settings.
*/
class CppDIBOFactory;
class GlobalEnv {
public:
/**
* Returns the instance of the CppDIBOFactory which in turn is used to
* instantiate C++ DIBOs. This call must not fail.
* @return pointer to CppDIBOFactory.
*/
virtual CppDIBOFactory* getCppDIBOFactory() const = 0;
/**
* Returns the instance of the Current DIDL document.
* @return pointer to DOMDocument.
*/
virtual DOMDocument* getCurrentDIDDocument() const = 0;
};
#endif
The platform implementation for a particular C++ DIBO will be obtained from the CppDIBOFactory object (see
subclause E.3 for the specification of the CppDIBOFactory interface) which shall be queried from the
GlobalEnv object.
E.5 C++ interface bindings for DIBOs
E.5.1 Introduction
This clause specifies the C++ interface bindings for the corresponding DIBOs as specified in the subclause
5.4.
E.5.2 DIDL document access and manipulation
In DIML base operations for accessing and manipulating the DIDL document objects are those specified by
the DOM Level 3 Core API as defined by W3C.
Any W3C DOM conformant C++ language binding supporting the Core module can be used, provided:
• The Core module interfaces of the W3C DOM specification are supported;
• The binding specifies an interface called “DOMDocument.h” which supports the Document interface
from the Core module;
• The binding specifies an interface called “DOMElement.h” which supports the Element interface from
the Core module.
NOTE For example, the C++ language binding for the DOM Level 3 Core API from Xerces – C++ 2.4 [1]
can be used. It provides the C++ bindings for these access and manipulation operations.
© ISO/IEC 2006 – All rights reserved 7
---------------------- Page: 10 ----------------------
ISO/IEC 21000-10:2006/Amd.1:2006(E)
E.5.3 DIDL document loading and saving
In DIML base operations for loading and saving a DIDL document are those specified by the DOM Level 3
Load and Save API as defined by W3C.
Any W3C DOM conformant C++ language binding supporting the Load and Save module can be used,
provided the Load and Save module interfaces of the W3C DOM specification are supported.
NOTE For example, the C++ language binding for the DOM Level 3 Load and Save API from Xerces – C++
2.4 [1] can be used. It provides the C++ bindings for these loading and saving operations.
E.5.4 DIA related operations
See 5.4.2.4.
#ifndef DIA_H
#define DIA_H
#include
#include "DIPError.h"
/**
* C++ interface bindings for the DIA related DIBOs.
*/
class DIA {
public:
/**
* Requests the adaptatio
...
Questions, Comments and Discussion
Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.