How to validate XMP's URI??

Hi,
I am a student in engeneering who is trying to build an onthology about metadata for my thesis.
I am using Protègè 3.4.4 as platform to build the onthology, and i am trying to import the XMP namespaces in order to have the structure of this standard available, but every attempt of import fails...
So i tried to validate the Uri about every XMP standard schema, with http://www.w3.org/RDF/Validator/  ,but only the Dublin Core could validate succesfully.
The error that the validator returns for the XMP basic schema (http://ns.adobe.com/xap/1.0/) is:
FatalError: The reference to entity "nl" must end with the ';'  delimiter.[Line = 59, Column = 104]
this is an error about special characters in html, and i corrected it, but after this one also other error are found....
for the other schemas the error returned is:
An attempt to load the RDF from URI 'http://ns.adobe.com/exif/1.0/'  failed.  (Document looks like HTML, ignored.)
Is there anyone who succeed using these namespaces? or there are any other equivalent namespaces i can get the rdfs from?

Thanks for your kind answer Jörg, I understood that the URI i was validating was the Adobe 's home page...
and I have found also a couple of useful statement in the XMP specifications:
pag 12 from pdf XMP DocSchema:
  A schema name, which is a URI that serves to uniquely identify the schema. It is simply a
  unique string. (Although it often looks like a URL, there might or might not be an actual
  Web page at the URI. In the case of Adobe namespaces, currently there is no corresponding
  Web page.)
pag 14 from pdf xmp_specification:
      The term “XMP Schema” used here to clearly distinguish this concept from other uses
      of the term “schema”, and notably from the W3C XML Schema language. An XMP
      Schema is typically less formal, defined by documentation instead of a machine
      readable schema file.
so now , everything is clearer.
thanks a lot
Simone

Similar Messages

  • How to validate XML against XSD and parse/save in one step using SAXParser?

    How to validate XML against XSD and parse/save in one step using SAXParser?
    I currently have an XML file and XSD. The XML file specifies the location of the XSD. In Java code I create a SAXParser with parameters indicating that it needs to validate the XML. However, SAXParser.parse does not validate the XML, but it does call my handler functions which save the elements/attributes in memory as it is read. On the other hand, XMLReader.parse does validate the XML against the XSD, but does not save the document in memory.
    My code can call XMLReader.parse to validate the XML followed by SAXParser.parse to save the XML document in memory. But this sound inefficient. Besides, while a valid document is being parsed by XMLReader, it can be changed to be invalid and saved, and XMLReader.parse would be looking at the original file and would think that the file is OK, and then SAXParser.parse would parse the document without errors.
    <Book xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="book.xsd" name="MyBook">
      <Chapter name="First Chapter"/>
      <Chapter name="Second Chapter">
        <Section number="1"/>
        <Section number="2"/>
      </Chapter>
    </Book>
    <?xml version="1.0" encoding="ISO-8859-1" ?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <xs:element name="Book">
    <xs:complexType>
      <xs:sequence>
       <xs:element name="Chapter" minOccurs="0" maxOccurs="unbounded">
        <xs:complexType>
         <xs:sequence>
          <xs:element name="Section" minOccurs="0" maxOccurs="unbounded">
           <xs:complexType>
            <xs:attribute name="xnumber"/>
          </xs:complexType>
          </xs:element>
         </xs:sequence>
         <xs:attribute name="name"/>
        </xs:complexType>
       </xs:element>
      </xs:sequence>
      <xs:attribute name="name"/>
    </xs:complexType>
    </xs:element>
    </xs:schema>
    public class SAXXMLParserTest
       public static void main(String[] args)
          try
             SAXParserFactory factory = SAXParserFactory.newInstance();
             factory.setNamespaceAware(true);
             factory.setValidating(true);
             SAXParser parser = factory.newSAXParser();
             parser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaLanguage",
                                "http://www.w3.org/2001/XMLSchema");
             BookHandler handler = new BookHandler();
             XMLReader reader = parser.getXMLReader();
             reader.setErrorHandler(handler);
             parser.parse("xmltest.dat", handler); // does not throw validation error
             Book book = handler.getBook();
             System.out.println(book);
             reader.parse("xmltest.dat"); // throws validation error because of 'xnumber' in the XSD
    public class Book extends Element
       private String name;
       private List<Chapter> chapters = new ArrayList<Chapter>();
       public Book(String name)
          this.name = name;
       public void addChapter(Chapter chapter)
          chapters.add(chapter);
       public String toString()
          StringBuilder builder = new StringBuilder();
          builder.append("<Book name=\"").append(name).append("\">\n");
          for (Chapter chapter: chapters)
             builder.append(chapter.toString());
          builder.append("</Book>\n");
          return builder.toString();
       public static class BookHandler extends DefaultHandler
          private Stack<Element> root = null;
          private Book book = null;
          public void startDocument()
             root = new Stack<Element>();
          public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException
             if (qName.equals("Book"))
                String name = attributes.getValue("name");
                root.push(new Book(name));
             else if (qName.equals("Chapter"))
                String name = attributes.getValue("name");
                Chapter child = new Chapter(name);
                ((Book)root.peek()).addChapter(child);
                root.push(child);
             else if (qName.equals("Section"))
                Integer number = Integer.parseInt(attributes.getValue("number"));
                Section child = new Section(number);
                ((Chapter)root.peek()).addSection(child);
                root.push(child);
          public void endElement(String uri, String localName, String qName) throws SAXException
             Element finished = root.pop();
             if (root.size() == 0)
                book = (Book) finished;
          public Book getBook()
             return book;
          public void error(SAXParseException e)
             System.out.println(e.getMessage());
          public void fatalError(SAXParseException e)
             error(e);
          public void warning(SAXParseException e)
             error(e);
    public class Chapter extends Element
       public static class Section extends Element
          private Integer number;
          public Section(Integer number)
             this.number = number;
          public String toString()
             StringBuilder builder = new StringBuilder();
             builder.append("<Section number=\"").append(number).append("\"/>\n");
             return builder.toString();
       private String name;
       private List<Section> sections = null;
       public Chapter(String name)
          this.name = name;
       public void addSection(Section section)
          if (sections == null)
             sections = new ArrayList<Section>();
          sections.add(section);
       public String toString()
          StringBuilder builder = new StringBuilder();
          builder.append("<Chapter name=\"").append(name).append("\">\n");
          if (sections != null)
             for (Section section: sections)
                builder.append(section.toString());
          builder.append("</Chapter>\n");
          return builder.toString();
    }Edited by: sn72 on Oct 28, 2008 1:16 PM

    Have you looked at the XML DB FAQ thread (second post) in this forum? It has some examples for validating XML against schemas.

  • How to validate numbers in char field.

    Hello all,
    I have one database column with char data type. This field should allow insert only
    numbers [ zero to nine] and plus symbol .. how to validate this?
    Pls help me..
    I.m using oracle 9i database. So it does not allow REG-EXP and WITH methods.. So give some
    sql coding to do this

    As this forum is for issues with the SQL Developer tool, you'll probably get more answers in the SQL And PL/SQL forum.
    Regards,
    K.

  • How to validate the dates in the table control ?

    How to validate the dates in the table control ?
    Can I write like this ?
    LOOP AT it_tab .
    CHAIN.
    FIELD : it_tab-strtdat,it_tab-enddat.
    module date_validation.
    ENDCHAIN.
    ENDLOOP.
    Module Date_validation.
    ranges : vdat type sy-datum.
    vdat-sign = 'I'.
    VDAT-LOW = it_tab-STRTDAT.
    VDAT-HIGH = it_tab-ENDDAT.
    VDAT-OPTION = 'BT'.
    APPEND VDAT.
    WHAT CODE I have to write here to validate ?
    and If I write like this How can we know which is the current row being add ?
    It loops total internal table ..?
    Bye,
    Muttu.

    Hi,
    I think there is no need to put chain endchain.
    To do validation you have to write module in PAI which does required validations.
    Thanks
    DARSHAN PATEL

  • How to validate material status in physical Inv Doc creation using MI01

    Hi Experts,
    I would like to know how to validate material status while creating physical inventory document using MI01 transaction.
    I tried to figure out a suitable BADI and customer exits ,but it didnt work out well.
    Kindly share your thoughts on how this can be achieved.
    Regards,
    Mohammed Aslam Rasheed

    Do you really create your inventory documents with this MI01 transaction manually by entering material for material?
    The real transaction for physical inventory is MI31. How do you want SAP to react if hundreds of materials are selected and inventory documents are created in a batch process?
    SAP takes care about the material status in MI04 and MI07 transactions.
    I am not aware of any exit for MI01 maintenance, you may consider Explicit and Implicit Enhancement Options

  • How to Validate a User on the click of a button in Oracle APEX

    Hi,
    How to Validate a User on the click of a button in Oracle APEX.
    say for e.g: I want to allow only a specific user to go beyond after clicking on a button and restrict all the other Users. Any ideas please.
    Thanks in Advance,
    Af

    Well , the actual idea was to hide the button for specific users and show the button only for some specific users... is this possible...?
    @ AndyH: yeah, what you have suggested also fits well for my requirement... Could you please let me know how can i achieve it...
    Regards,
    Af

  • How to validate the file path when downloading.

    Hi
    How to validate the file path when downloading to Presentation or application Server.

    hiii
    you can validate file path by following way
    REPORT zvalidate.
    TYPE-POOLS: abap.
    DATA: w_direc TYPE string.
    DATA: w_bool TYPE abap_bool.
    w_dir = 'c:\Myfolder\'.
    CALL METHOD cl_gui_frontend_services=>directory_exist
    EXPORTING
    directory = w_direc
    RECEIVING
    result = w_bool
    EXCEPTIONS
    cntl_error = 1
    error_no_gui = 2
    wrong_parameter = 3
    not_supported_by_gui = 4
    OTHERS = 5.
    IF NOT w_bool IS INITIAL.
    WRITE:/ 'Directory exists.'.
    ELSE.
    WRITE:/ 'Directory does not exist.'.
    ENDIF.
    regards
    twinkal

  • How to write XMP changes back to Photoshop DOM in CS SDK?

    Hello,
    I'm learning to use the ActionScript library for XMP in conjunction with the CS SDK to build Photoshop panels.
    I see from the Extension Builder samples that the AssetFragger application demonstrates how to use XMP for annotating comments to image files in Illustrator using com.adobe.illustrator.  In the runSet() method the XMP data is manipulated then the changes are stored in the document.  So after creating a new XMP node ( XMPArray.newBag() ) it uses doc.XMPString to write the serialized XMP back to the document, then sets doc.saved = false.
            public function runSet():void
                var app:Application = Illustrator.app;
                var doc:Document = app.activeDocument;
                var updateText:String = AssetFraggerModel.getInstance().xmlTextNugget;
                 var xmpString : String = doc.XMPString;
                var xmpMeta : XMPMeta = new XMPMeta(xmpString);
                var ns : Namespace = new Namespace(xmpMeta.getNamespace("xmp"));
                xmpMeta.ns::AssetFraggerDescription = XMPArray.newBag();
                xmpMeta.ns::AssetFraggerDescription[1] = updateText;
                var tmp : String = xmpMeta.serialize();
                doc.XMPString = tmp;   
                doc.saved = false;
    However, using com.adobe.photoshop instead, the XMLString property on the Application activeDocument instance is not available, the doc.saved property is not modifiable (marked as read-only), and the Photoshop Application activeDocument has a xmpMetadata.rawData property available whereas Illustrator did not.  The Photoshop activeDocument.xmpMetadata.rawData is marked as read only, so it can be used to get the plain XMP as a string directly, but once modified the XMP cannot be updated in that property.  Example:
            public static function traceXMP():void
                var app:Application = Photoshop.app;
                var doc:Document = app.activeDocument;
                var xmpString:String = doc.xmpMetadata.rawData;
                var xmpMeta:XMPMeta = new XMPMeta(xmpString);
                var metaXML:XML = xmpMeta.serializeToXML();
                var Iptc4xmpCore:Namespace = new Namespace(XMPConst.Iptc4xmpCore);
                // demonstrate that a leaf in IPTC can be changed and written to the trace console
                xmpMeta.Iptc4xmpCore::CreatorContactInfo.Iptc4xmpCore::CiUrlWork = 'http://test.com/';
                trace(ObjectUtil.toString(xmpMeta.Iptc4xmpCore::CreatorContactInfo.Iptc4xmpCore::CiUrlWor k.toString()));
                // but now how to write the XMP change back to the Photoshop DOM?
    My question is, for a given image file exported as from Lightroom that is rich in custom IPTC metadata, how does one update the metadata in Photosohp via XMP and the CS SDK?  I was not able to extract this information from the Advanced Topics: Working with XMP Metadata chapter of the CS SDK documentation
    A real, and complete code example would be greatly appreciated over a pseudocode example.
    Thank you in advance.
    Steven Erat

    Ah ha.  Found the problem, thanks to Ian.  When I saw the inline help appear in Extension Builder for app.activeDocument.xmpMetadata, it indicated that the node as [Read Only], however, the leaf app.activeDocument.xmpMetadata.rawData is in fact not read only. I incorrectly assumed rawData was not writeable when in fact it is.

  • How to validate a date in message mapping

    Hi experts,
                    how to validate a date in message mapping. For ex:  if date comes as 2008/02/31, then file it shold not get processed.how to achieve this in message mapping. Please help .
    Thanks&Regards,
    Reyaz Hussain

    Hi,
    There are few simple ways for date validation as follow,
    1.If you would like to handle it in XI only, then in message mapping you could verify about it with the help of generating smart exception.
    For e.g in mapping there is one Date conversion API i.e. somthing DateTransformation It converts the incoming date format to required format. Here give the date format i.e expected from Sender File.
    If in case the format miss-matched then it will create the exception.
    You could handle this exception with the use of [Alert notification|http://help.sap.com/saphelp_nw04/helpdata/en/2c/abb2e7ff6311d194c000a0c93033f7/frameset.htm] and could be even able to notify to sender system about it.
    2. The another solution is easy for SAP synchornous communication --If you are passing the file data to SAP, then you could use below function modules to verify date format in receiver RFC/BAPI or inbound IDOC program. If the sy-subrc is not 0 then don't process further.
    CONVERT_DATE_FORMAT
    ISU_DATE_FORMAT_CHECK
    Thanks
    Swarup

  • How to validate the  FI-AR& AP& FI-GL   and CO-PA extractor in R3

    Hi,
    I would like to do the integration testing in R/3 and BW.
    How to validate  Standard FI-AR& AP& FI-GL  and CO-PA extractor in R/3.
    Snapshot result of RSA3 and the tables?
    What are the tables and extractors need to be validate for FI-AR& AP& FI-GL   and CO-PA extractor in R3.
    As per our integration testing for FI-AR& AP& FI-GL   and CO-PA extractor in R3.
    How would i like to do the testing in BW QA system.
    Please some one will help me in this and answer would be great appreciate.

    Solved

  • How to validate Quantity field in TV - Inputfield ?

    Hello All,
            I'm using a table view to show the output .
    IN this table view I made 2 fields as Input fields.
    Both the fields are Quantity fields.
    Now when the user enters a value in this Quantity field I want to validate it with respect to it's units .
    How can I do that ?
    In my case if the user enters correct value it works but when he enters a wrong value my BSP is going for a dump.
    I tried to debug the<b> LIPS table</b> to verify how SAP was handling this checking for the field <b>LFIMG</b>. But there there is a statement called chain --endchain.
    SO there is no chance for debugging.
    My code is as follows :-
            LOOP AT gt_final INTO wa_final.
              CLEAR: gv_row,lv_qty,lv_string,gv_len,gv_cell_id1.
              gv_row = sy-tabix.
              gv_len = STRLEN( gv_row ).
              gv_len = gv_len - 1.
    * Modify the Third Column
              CONCATENATE 'INB01_TV_ID' '_' gv_row(gv_len) '_' '3' INTO gv_cell_id1 .
              lv_string = request->get_form_field( name = gv_cell_id1 ).
              WRITE lv_string TO lv_qty  UNIT wa_final-units.
              CLEAR :wa_final-del_quantity.
              wa_final-del_quantity = lv_qty.
              MODIFY gt_final FROM wa_final TRANSPORTING del_quantity.
            ENDLOOP.
    Can anyone tell me how to validate the entry for the Quantity filed ?
    Regards,
    Deepu.K
    I have one more Question .
    Whenever BSP goes for a dump in this case I want to handle this by a message .
    Is it possible ?
    Message was edited by:
            deepu k

    Hello Raja,
           I want to validate the entry in the QUantity field with respect to the Unit of the Quantity.
    I.e say for example I have a unit as PC (pieces) then the quantity must be only of thousands,lakks and so..on......but not in points i.e a piece quantity must be full either 200 ,2 lakhs or 2 pieces but not 2.5 pieces.
    SO now if the user enters 2.5 it's a wrong value as the quantity for the Unit PIECES can't have half-piece. (2.5 = 2 + 0.5) .SO i want to validate this .
    I hope I'm clear.
    How should I do ?
    Regards,
    Deepu.k

  • How to validate a program in background

    hello folks,
    i need to validate my program, my program should run only in background
    in case if it runs in foreground it should give error message. how to validate my
    program.
    can any one just tell the procedure how to do it.
    any help will be greatly appreciated,
    thanks in advance.
    regards,
    cnu

    Hello CNU,
    following snippet should do.
    Regards
      Klaus
    if ( 'X' ne sy-Batch ).
      message e000 with 'Only in Batch'(BTC).
    endif.

  • How to validate a filed in a search help which is created in se11

    hi
    i got a requirement that validate a search help. i created a ztable with 3 fileds for that one i have to create a search help so help me to how to validate fields in a search help.
    regards
    krishna

    Hello Krishna,
    What do you mean by validating a field? Usually you use a search help to display possible values for a certain input field based on values in another table. You can restrict the values that are displayed by certain conditions if you need to.
    If you want to allow only values based on complex conditions or authorizations of the user, you can always create a search help exit and in there you have complete control over what the user is allowed to see in the search help and what he is allowed to select.
    Function Module F4IF_SHLP_EXIT_EXAMPLE gives you an idea what you can do in a search help exit.
    Regards,
    Michael

  • How to validate a session object in jsp?

    Hi All,
    i am facing a problem.The problem is how to validate the session object object in jsp.I have written a java script by using a defined function as setInterval and has given 5 mintues if the user is idle and will show a pop up menu before time out the session but in case of page active still this pop up menu is coming. The java script as follows.
    function SetTimer(){
         //How long before timeout (should be a few minutes before your server's timeout
         //set timer to call function to confirm update
         if(timeoutMinutes)
         timerObj = setInterval("ConfirmUpdate()",60000);
    function clearTimerFn(){
              timerCount = 0;
              clearInterval(timerObj);
              //timerObj = setInterval("ConfirmUpdate()",60000);
    function ConfirmUpdate(){
         //Ask them to extend
         if(confirm("Your session is about to expire. Press 'OK' to renew your session.")){
              //load server side page if ok
              var url = "ajaxSessionchecker.do?sessionvalidate=sessionvalid";
              LoadXMLDoc(url);
    And in jsp i am calling this js function as
    <%session=request.getSession(false);
              if(session.getLastAccessedTime()==60000){ %>
              <script type="text/JavaScript">
         clearTimerFn();
    </script>
    <%}else{
    session.setMaxInactiveInterval(-1000);} %>
    could you pls help me out?

    The reason for doing this is when ever i come to this user.jsp from account.jsp with a different account number this user.jsp is not refreshed and i still
    see the same old user.jsp for the previous account that i naviated before. Also please let me know if there is any other approach to acheive this taskDoes refreshing the page by pushing F5 solve the problem?
    If so, then the browser is caching the page, despite your attempts to stop it.

  • How to validate multiple lines which is exist in the form builder at the same session

    Hi All,
    we are working on oracle Forms personalization to trigger the message at the point of saving multiple lines rather than requiring each line to be save individually. Currently the oracle form is allowing to user to enter two distinct lines that have same resource and basis type in BOM.
    Currently the Oracle form is allowing to enter the duplicate combination and not giving any error message even we enter the same combination of data.
    As per the customer requirement, they don’t want to validate the data while creating the records but when they try to save the form, in that case it should validate all the records at a time then need to display the appropriate message.
    Customer don’t want to customize the Oracle standard form. Here we have only option to use form personalization or through custom.pll.
    Any idea on how to validate multiple lines which is exist in the form builder at the same session as before inserting the record itself need to perform the validations for all the records.
    Thanks for your help in this regard.
    Regards,
    Thirupathi

    you can write a post script which will do the necessary tasks.
    I mean, once you are done with inserting records into these tables, exeute another procedure which will insert these "extra" records, based on some logic.
    you may not be able use DB trigger as it may generate mutating error or if you don't write it carefully, it will go into recursive loops as you are refering to same tables.
    HTH

Maybe you are looking for