Class PropertyIDMap

  • All Implemented Interfaces:
    java.util.Map<java.lang.Long,​java.lang.String>

    public class PropertyIDMap
    extends java.lang.Object
    implements java.util.Map<java.lang.Long,​java.lang.String>
    This is a dictionary which maps property ID values to property ID strings. The methods getSummaryInformationProperties() and getDocumentSummaryInformationProperties() return singleton PropertyIDMaps. An application that wants to extend these maps should treat them as unmodifiable, copy them and modify the copies. Trying to modify the map directly will cause exceptions UnsupportedOperationException to be thrown.
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int PID_APPNAME
      ID of the property that denotes the application that created the document
      static int PID_AUTHOR
      ID of the property that denotes the document's author
      static int PID_BEHAVIOUR
      The Behavior property, if present, MUST have the property identifier 0x80000003, MUST NOT have a property name, and MUST have type VT_UI4 (0x0013).
      static int PID_BYTECOUNT
      Number of bytes.
      static int PID_CATEGORY
      The entry is a string denoting the category the file belongs to, e.g.
      static int PID_CCHWITHSPACES
      The entry specifies an estimate of the number of characters in the document, including whitespace, as an integer
      static int PID_CHARCOUNT
      ID of the property that denotes the number of characters in the document
      static int PID_CODEPAGE
      The entry denotes a code page.
      static int PID_COMMENTS
      ID of the property that denotes the document's comments
      static int PID_COMPANY
      This entry contains the company name.
      static int PID_CONTENTSTATUS
      This entry contains a string of the document status.
      static int PID_CONTENTTYPE
      This entry contains a string of the content type of the file.
      static int PID_CREATE_DTM
      ID of the property that denotes the date and time the document was created.
      static int PID_DICTIONARY
      The entry is a dictionary.
      static int PID_DIGSIG
      This entry contains the VBA digital signature for the VBA project embedded in the document.
      static int PID_DOCPARTS
      This entry contains the names of document parts (word: names of the documents in the master document, excel: sheet names, power point: slide titles, binder: document names).
      static int PID_DOCVERSION
      This entry contains a string of the document version, but normally should be empty
      static int PID_EDITTIME
      ID of the property that denotes the document's edit time
      static int PID_HEADINGPAIR
      This entry denotes an internally used property.
      static int PID_HIDDENCOUNT
      Number of hidden slides.
      static int PID_HYPERLINKSCHANGED
      This entry contains a boolean which marks if the User Defined Property Set has been updated outside of the Application, if so the hyperlinks should be updated on document load.
      static int PID_KEYWORDS
      ID of the property that denotes the document's keywords
      static int PID_LANGUAGE
      This entry contains a string of the document language, but normally should be empty.
      static int PID_LASTAUTHOR
      ID of the property that denotes the document's last author
      static int PID_LASTPRINTED
      ID of the property that denotes the date and time the document was last printed
      static int PID_LASTSAVE_DTM
      ID of the property that denotes the date and time the document was saved
      static int PID_LINECOUNT
      Number of lines.
      static int PID_LINKSDIRTY
      If this entry is -1 the links are dirty and should be re-evaluated.
      static int PID_LOCALE
      The Locale property, if present, MUST have the property identifier 0x80000000, MUST NOT have a property name, and MUST have type VT_UI4 (0x0013).
      static int PID_MANAGER
      This entry contains the name of the project manager.
      static int PID_MAX
      The highest well-known property ID.
      static int PID_MMCLIPCOUNT
      Number of multimedia clips, e.g.
      static int PID_NOTECOUNT
      Number of slides with notes.
      static int PID_PAGECOUNT
      ID of the property that denotes the number of pages in the document
      static int PID_PARCOUNT
      Number of paragraphs.
      static int PID_PRESFORMAT
      Target format for power point presentation, e.g.
      static int PID_REVNUMBER
      ID of the property that denotes the document's revision number
      static int PID_SCALE
      This entry is set to -1 when scaling of the thumbnail is desired.
      static int PID_SECURITY
      ID of the property that denotes whether read/write access to the document is allowed or whether is should be opened as read-only.
      static int PID_SLIDECOUNT
      Number of slides in a power point presentation.
      static int PID_SUBJECT
      ID of the property that denotes the document's subject
      static int PID_TEMPLATE
      ID of the property that denotes the document's template
      static int PID_THUMBNAIL
      ID of the property that denotes the document's thumbnail
      static int PID_TITLE
      ID of the property that denotes the document's title
      static int PID_VERSION
      This entry contains the version of the Application which wrote the Property set, stored with the two high order bytes having the major version number, and the two low order bytes the minor version number.
      static int PID_WORDCOUNT
      ID of the property that denotes the number of words in the document
      static java.lang.String UNDEFINED
      A property without a known name is described by this string.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      boolean containsKey​(java.lang.Object key)  
      boolean containsValue​(java.lang.Object value)  
      java.util.Set<java.util.Map.Entry<java.lang.Long,​java.lang.String>> entrySet()  
      java.lang.String get​(java.lang.Object key)  
      static PropertyIDMap getDocumentSummaryInformationProperties()  
      static PropertyIDMap getFallbackProperties()
      Returns a property map, which is only used as a fallback, i.e.
      static PropertyIDMap getSummaryInformationProperties()  
      boolean isEmpty()  
      java.util.Set<java.lang.Long> keySet()  
      static void main​(java.lang.String[] args)
      For the most basic testing.
      java.lang.String put​(java.lang.Long key, java.lang.String value)  
      void putAll​(java.util.Map<? extends java.lang.Long,​? extends java.lang.String> m)  
      java.lang.String remove​(java.lang.Object key)  
      int size()  
      java.util.Collection<java.lang.String> values()  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Map

        compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
    • Field Detail

      • PID_TITLE

        public static final int PID_TITLE
        ID of the property that denotes the document's title
        See Also:
        Constant Field Values
      • PID_SUBJECT

        public static final int PID_SUBJECT
        ID of the property that denotes the document's subject
        See Also:
        Constant Field Values
      • PID_AUTHOR

        public static final int PID_AUTHOR
        ID of the property that denotes the document's author
        See Also:
        Constant Field Values
      • PID_KEYWORDS

        public static final int PID_KEYWORDS
        ID of the property that denotes the document's keywords
        See Also:
        Constant Field Values
      • PID_COMMENTS

        public static final int PID_COMMENTS
        ID of the property that denotes the document's comments
        See Also:
        Constant Field Values
      • PID_TEMPLATE

        public static final int PID_TEMPLATE
        ID of the property that denotes the document's template
        See Also:
        Constant Field Values
      • PID_LASTAUTHOR

        public static final int PID_LASTAUTHOR
        ID of the property that denotes the document's last author
        See Also:
        Constant Field Values
      • PID_REVNUMBER

        public static final int PID_REVNUMBER
        ID of the property that denotes the document's revision number
        See Also:
        Constant Field Values
      • PID_EDITTIME

        public static final int PID_EDITTIME
        ID of the property that denotes the document's edit time
        See Also:
        Constant Field Values
      • PID_LASTPRINTED

        public static final int PID_LASTPRINTED
        ID of the property that denotes the date and time the document was last printed
        See Also:
        Constant Field Values
      • PID_CREATE_DTM

        public static final int PID_CREATE_DTM
        ID of the property that denotes the date and time the document was created.
        See Also:
        Constant Field Values
      • PID_LASTSAVE_DTM

        public static final int PID_LASTSAVE_DTM
        ID of the property that denotes the date and time the document was saved
        See Also:
        Constant Field Values
      • PID_PAGECOUNT

        public static final int PID_PAGECOUNT
        ID of the property that denotes the number of pages in the document
        See Also:
        Constant Field Values
      • PID_WORDCOUNT

        public static final int PID_WORDCOUNT
        ID of the property that denotes the number of words in the document
        See Also:
        Constant Field Values
      • PID_CHARCOUNT

        public static final int PID_CHARCOUNT
        ID of the property that denotes the number of characters in the document
        See Also:
        Constant Field Values
      • PID_THUMBNAIL

        public static final int PID_THUMBNAIL
        ID of the property that denotes the document's thumbnail
        See Also:
        Constant Field Values
      • PID_APPNAME

        public static final int PID_APPNAME
        ID of the property that denotes the application that created the document
        See Also:
        Constant Field Values
      • PID_SECURITY

        public static final int PID_SECURITY
        ID of the property that denotes whether read/write access to the document is allowed or whether is should be opened as read-only. It can have the following values:
        Value Description
        0 No restriction
        2 Read-only recommended
        4 Read-only enforced
        See Also:
        Constant Field Values
      • PID_DICTIONARY

        public static final int PID_DICTIONARY
        The entry is a dictionary.
        See Also:
        Constant Field Values
      • PID_CODEPAGE

        public static final int PID_CODEPAGE
        The entry denotes a code page.
        See Also:
        Constant Field Values
      • PID_CATEGORY

        public static final int PID_CATEGORY
        The entry is a string denoting the category the file belongs to, e.g. review, memo, etc. This is useful to find documents of same type.
        See Also:
        Constant Field Values
      • PID_PRESFORMAT

        public static final int PID_PRESFORMAT
        Target format for power point presentation, e.g. 35mm, printer, video etc.
        See Also:
        Constant Field Values
      • PID_PARCOUNT

        public static final int PID_PARCOUNT
        Number of paragraphs.
        See Also:
        Constant Field Values
      • PID_SLIDECOUNT

        public static final int PID_SLIDECOUNT
        Number of slides in a power point presentation.
        See Also:
        Constant Field Values
      • PID_NOTECOUNT

        public static final int PID_NOTECOUNT
        Number of slides with notes.
        See Also:
        Constant Field Values
      • PID_HIDDENCOUNT

        public static final int PID_HIDDENCOUNT
        Number of hidden slides.
        See Also:
        Constant Field Values
      • PID_MMCLIPCOUNT

        public static final int PID_MMCLIPCOUNT
        Number of multimedia clips, e.g. sound or video.
        See Also:
        Constant Field Values
      • PID_SCALE

        public static final int PID_SCALE
        This entry is set to -1 when scaling of the thumbnail is desired. Otherwise the thumbnail should be cropped.
        See Also:
        Constant Field Values
      • PID_HEADINGPAIR

        public static final int PID_HEADINGPAIR
        This entry denotes an internally used property. It is a vector of variants consisting of pairs of a string (VT_LPSTR) and a number (VT_I4). The string is a heading name, and the number tells how many document parts are under that heading.
        See Also:
        Constant Field Values
      • PID_DOCPARTS

        public static final int PID_DOCPARTS
        This entry contains the names of document parts (word: names of the documents in the master document, excel: sheet names, power point: slide titles, binder: document names).
        See Also:
        Constant Field Values
      • PID_MANAGER

        public static final int PID_MANAGER
        This entry contains the name of the project manager.
        See Also:
        Constant Field Values
      • PID_COMPANY

        public static final int PID_COMPANY
        This entry contains the company name.
        See Also:
        Constant Field Values
      • PID_LINKSDIRTY

        public static final int PID_LINKSDIRTY
        If this entry is -1 the links are dirty and should be re-evaluated.
        See Also:
        Constant Field Values
      • PID_CCHWITHSPACES

        public static final int PID_CCHWITHSPACES
        The entry specifies an estimate of the number of characters in the document, including whitespace, as an integer
        See Also:
        Constant Field Values
      • PID_HYPERLINKSCHANGED

        public static final int PID_HYPERLINKSCHANGED
        This entry contains a boolean which marks if the User Defined Property Set has been updated outside of the Application, if so the hyperlinks should be updated on document load.
        See Also:
        Constant Field Values
      • PID_VERSION

        public static final int PID_VERSION
        This entry contains the version of the Application which wrote the Property set, stored with the two high order bytes having the major version number, and the two low order bytes the minor version number.
        See Also:
        Constant Field Values
      • PID_DIGSIG

        public static final int PID_DIGSIG
        This entry contains the VBA digital signature for the VBA project embedded in the document.
        See Also:
        Constant Field Values
      • PID_CONTENTTYPE

        public static final int PID_CONTENTTYPE
        This entry contains a string of the content type of the file.
        See Also:
        Constant Field Values
      • PID_CONTENTSTATUS

        public static final int PID_CONTENTSTATUS
        This entry contains a string of the document status.
        See Also:
        Constant Field Values
      • PID_LANGUAGE

        public static final int PID_LANGUAGE
        This entry contains a string of the document language, but normally should be empty.
        See Also:
        Constant Field Values
      • PID_DOCVERSION

        public static final int PID_DOCVERSION
        This entry contains a string of the document version, but normally should be empty
        See Also:
        Constant Field Values
      • PID_MAX

        public static final int PID_MAX
        The highest well-known property ID. Applications are free to use higher values for custom purposes. (This value is based on Office 12, earlier versions of Office had lower values)
        See Also:
        Constant Field Values
      • PID_LOCALE

        public static final int PID_LOCALE
        The Locale property, if present, MUST have the property identifier 0x80000000, MUST NOT have a property name, and MUST have type VT_UI4 (0x0013). If present, its value MUST be a valid language code identifier as specified in [MS-LCID]. Its value is selected in an implementation-specific manner.
        See Also:
        Constant Field Values
      • PID_BEHAVIOUR

        public static final int PID_BEHAVIOUR
        The Behavior property, if present, MUST have the property identifier 0x80000003, MUST NOT have a property name, and MUST have type VT_UI4 (0x0013). A version 0 property set, indicated by the value 0x0000 for the Version field of the PropertySetStream packet, MUST NOT have a Behavior property. If the Behavior property is present, it MUST have one of the following values.
        • 0x00000000 = Property names are case-insensitive (default)
        • 0x00000001 = Property names are case-sensitive.
        See Also:
        Constant Field Values
      • UNDEFINED

        public static final java.lang.String UNDEFINED
        A property without a known name is described by this string.
        See Also:
        Constant Field Values
    • Method Detail

      • getSummaryInformationProperties

        public static PropertyIDMap getSummaryInformationProperties()
        Returns:
        the Summary Information properties singleton
      • getDocumentSummaryInformationProperties

        public static PropertyIDMap getDocumentSummaryInformationProperties()
        Returns:
        The Document Summary Information properties singleton.
      • size

        public int size()
        Specified by:
        size in interface java.util.Map<java.lang.Long,​java.lang.String>
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Map<java.lang.Long,​java.lang.String>
      • containsKey

        public boolean containsKey​(java.lang.Object key)
        Specified by:
        containsKey in interface java.util.Map<java.lang.Long,​java.lang.String>
      • containsValue

        public boolean containsValue​(java.lang.Object value)
        Specified by:
        containsValue in interface java.util.Map<java.lang.Long,​java.lang.String>
      • get

        public java.lang.String get​(java.lang.Object key)
        Specified by:
        get in interface java.util.Map<java.lang.Long,​java.lang.String>
      • put

        public java.lang.String put​(java.lang.Long key,
                                    java.lang.String value)
        Specified by:
        put in interface java.util.Map<java.lang.Long,​java.lang.String>
      • remove

        public java.lang.String remove​(java.lang.Object key)
        Specified by:
        remove in interface java.util.Map<java.lang.Long,​java.lang.String>
      • putAll

        public void putAll​(java.util.Map<? extends java.lang.Long,​? extends java.lang.String> m)
        Specified by:
        putAll in interface java.util.Map<java.lang.Long,​java.lang.String>
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Map<java.lang.Long,​java.lang.String>
      • keySet

        public java.util.Set<java.lang.Long> keySet()
        Specified by:
        keySet in interface java.util.Map<java.lang.Long,​java.lang.String>
      • values

        public java.util.Collection<java.lang.String> values()
        Specified by:
        values in interface java.util.Map<java.lang.Long,​java.lang.String>
      • entrySet

        public java.util.Set<java.util.Map.Entry<java.lang.Long,​java.lang.String>> entrySet()
        Specified by:
        entrySet in interface java.util.Map<java.lang.Long,​java.lang.String>
      • main

        public static void main​(java.lang.String[] args)
        For the most basic testing.
        Parameters:
        args - The command-line arguments