org.apache.pdfbox.preflight.font.util

## Class FontMetaDataValidation

- java.lang.Object
- - org.apache.pdfbox.preflight.font.util.FontMetaDataValidation

    public class FontMetaDataValidation
    extends Object

Class used to validate the MetaData entry of the Font File Stream dictionary.

### Constructor Summary

Constructors
Constructor and Description
`FontMetaDataValidation()`

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `analyseFontName(org.apache.xmpbox.XMPMetadata metadata, org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc, List<ValidationResult.ValidationError> ve)` Value of the dc:title must be the same as the FontName in the font descriptor.
`boolean` `analyseRights(org.apache.xmpbox.XMPMetadata metadata, org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc, List<ValidationResult.ValidationError> ve)` If XMP MetaData is present, they must have the following information : dc:rights Marked (with the value true) Owner UsageTerms
`List<ValidationResult.ValidationError>` `validatePDFAIdentifer(org.apache.xmpbox.XMPMetadata metadata, org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### FontMetaDataValidation

    public FontMetaDataValidation()

### Method Detail

#### validatePDFAIdentifer

    public List<ValidationResult.ValidationError> validatePDFAIdentifer(org.apache.xmpbox.XMPMetadata metadata,
                                                                        org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc)
                                                                 throws ValidationException

Throws:
  `ValidationException`

#### analyseFontName

    public boolean analyseFontName(org.apache.xmpbox.XMPMetadata metadata,
                                   org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc,
                                   List<ValidationResult.ValidationError> ve)

Value of the dc:title must be the same as the FontName in the font descriptor.

Parameters:
  `metadata` - XMPMetaData of the Font File Stream
  `fontDesc` - The FontDescriptor dictionary
  `ve` - the list of validation error to update if the validation fails

#### analyseRights

    public boolean analyseRights(org.apache.xmpbox.XMPMetadata metadata,
                                 org.apache.pdfbox.pdmodel.font.PDFontDescriptor fontDesc,
                                 List<ValidationResult.ValidationError> ve)

If XMP MetaData is present, they must have the following information :

- dc:rights
- Marked (with the value true)
- Owner
- UsageTerms

Parameters:
  `metadata` - XMPMetaData of the Font File Stream
  `fontDesc` - The FontDescriptor dictionary
  `ve` - the list of validation error to update if the validation fails
Returns:
  true if the analysis found no problems, false if it did.