StructureElement
StructureElement
General
StructureElement és una classe en FOSS per Java.
Representa un element estructural en l’arbre de la estructura lògica (ISO 32000-1:2008, §14.7.2, Taula 323).
Aquesta classe proporciona 21 mètodes per treballar amb objectes StructureElement en programes Java. Els mètodes disponibles inclouen: StructureElement, appendChild, appendMarkedContent, getActualText, getAllKids, getAlternateDescription, getChildElements, getExpandedForm, getID, getLanguage, getParent, getPdfDictionary, i 9 mètodes addicionals. Tots els membres públics són accessibles a qualsevol aplicació Java després d’instal·lar el paquet FOSS per Java. Propietats: actualText, allKids, alternateDescription, childElements, expandedForm, iD, i 5 més.
Propietats
| Nom | Tipus de productes | Access | Descripció |
|---|---|---|---|
pdfDictionary | PdfDictionary | Llegeix. | Retorna el diccionari PDF subjacent. |
structureType | StructureTypeStandard | Llegeix. | Retorna el tipus d’estructura (per exemple, P, H1, Taula, Div). |
title | String | Llegeix. | Retorna el títol (/T). |
language | String | Llegeix. | Retorna el llenguatge (/Lang). |
alternateDescription | String | Llegeix. | Retorna la descripció alternativa (/Alt). |
actualText | String | Llegeix. | Retorna el text real (/ActualText). |
expandedForm | String | Llegeix. | Retorna la forma expandida (/E). |
iD | String | Llegeix. | Retorna l’ID de l"element (/ID). |
childElements | ElementList | Llegeix. | Retorna només els fills de StructureElement (filtra MCR, OBJR, enters). |
allKids | List<Object> | Llegeix. | Retorna tots els elements fills: StructureElements, MarkedContentReferences i MCIDs. |
parent | StructureElement | Llegeix. | Retorna l’element principal, o {@code null} per a elements de nivell raí. |
Mètodes
| Signature | Descripció |
|---|---|
StructureElement(dict: PdfDictionary, parser: PDFParser) | Crea un element de estructura que envolta el diccionari donat. |
getPdfDictionary() → PdfDictionary | Retorna el diccionari PDF subjacent. |
getStructureType() → StructureTypeStandard | Retorna el tipus d’estructura (per exemple, P, H1, Taula, Div). |
setStructureType(type: StructureTypeStandard) | Estableix el tipus d’estructura. |
getTitle() → String | Retorna el títol (/T). |
setTitle(title: String) | Estableix el títol (/T). |
getLanguage() → String | Retorna el llenguatge (/Lang). |
setLanguage(lang: String) | Estableix l’idioma (/Lang). |
getAlternateDescription() → String | Retorna la descripció alternativa (/Alt). |
setAlternateDescription(alt: String) | Estableix la descripció alternativa (/Alt). |
getActualText() → String | Retorna el text real (/ActualText). |
setActualText(text: String) | Estableix el text real (/ActualText). |
getExpandedForm() → String | Retorna la forma expandida (/E). |
setExpandedForm(expanded: String) | Estableix la forma expandida (/E). |
getID() → String | Retorna l’ID de l"element (/ID). |
setID(id: String) | Estableix l’ID de l’element (/ID). |
getChildElements() → ElementList | Retorna només els fills de StructureElement (filtra MCR, OBJR, enters). |
getAllKids() → List<Object> | Retorna tots els elements fills: StructureElements, MarkedContentReferences i MCIDs. |
appendChild(child: StructureElement) | Anexa un element de estructura infantil. |
appendMarkedContent(mcid: int, page: PdfDictionary) | Anexa una referència de contingut marcat (MCID) com a nen. |
getParent() → StructureElement | Retorna l’element principal, o {@code null} per a elements de nivell raí. |