remove some more deprecated code

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1879298 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
PJ Fanning 2020-06-28 08:42:23 +00:00
parent 4671a43b71
commit 241c7e2bb2
5 changed files with 1 additions and 135 deletions

View File

@ -39,60 +39,6 @@ import org.apache.poi.util.LittleEndianOutput;
* The ClassID (or CLSID) is a UUID - see RFC 4122
*/
public class ClassID implements Duplicatable, GenericRecord {
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID OLE10_PACKAGE = ClassIDPredefined.OLE_V1_PACKAGE.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID PPT_SHOW = ClassIDPredefined.POWERPOINT_V8.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID XLS_WORKBOOK = ClassIDPredefined.EXCEL_V7_WORKBOOK.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID TXT_ONLY = ClassIDPredefined.TXT_ONLY.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL_V3 = ClassIDPredefined.EXCEL_V3.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL_V3_CHART = ClassIDPredefined.EXCEL_V3_CHART.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL_V3_MACRO = ClassIDPredefined.EXCEL_V3_MACRO.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL95 = ClassIDPredefined.EXCEL_V7.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL95_CHART = ClassIDPredefined.EXCEL_V7_CHART.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL97 = ClassIDPredefined.EXCEL_V8.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL97_CHART = ClassIDPredefined.EXCEL_V8_CHART.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2003 = ClassIDPredefined.EXCEL_V11.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2007 = ClassIDPredefined.EXCEL_V12.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2007_MACRO= ClassIDPredefined.EXCEL_V12_MACRO.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2007_XLSB = ClassIDPredefined.EXCEL_V12_XLSB.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2010 = ClassIDPredefined.EXCEL_V14.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2010_CHART= ClassIDPredefined.EXCEL_V14_CHART.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EXCEL2010_ODS = ClassIDPredefined.EXCEL_V14_ODS.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID WORD95 = ClassIDPredefined.WORD_V7.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID WORD97 = ClassIDPredefined.WORD_V8.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID WORD2007 = ClassIDPredefined.WORD_V12.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID WORD2007_MACRO = ClassIDPredefined.WORD_V12_MACRO.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID POWERPOINT97 = ClassIDPredefined.POWERPOINT_V8.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID POWERPOINT95 = ClassIDPredefined.POWERPOINT_V7.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID POWERPOINT2007 = ClassIDPredefined.POWERPOINT_V12.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID POWERPOINT2007_MACRO = ClassIDPredefined.POWERPOINT_V12_MACRO.getClassID();
/** @deprecated use enum {@link ClassIDPredefined} */ @Deprecated
public static final ClassID EQUATION30 = ClassIDPredefined.EQUATION_V3.getClassID();
/** The number of bytes occupied by this object in the byte stream. */
public static final int LENGTH = 16;

View File

@ -788,26 +788,6 @@ public class PropertySet {
}
/**
* If the {@link PropertySet} has only a single section this method returns it.
*
* @return The singleSection value
*
* @deprecated superfluous convenience method
*/
@Deprecated
@Removal(version="5.0.0")
public Section getSingleSection() {
final int sectionCount = getSectionCount();
if (sectionCount != 1) {
throw new NoSingleSectionException("Property set contains " + sectionCount + " sections.");
}
return sections.get(0);
}
/**
* Returns {@code true} if the {@code PropertySet} is equal
* to the specified parameter, else {@code false}.

View File

@ -22,7 +22,6 @@ import java.util.List;
import org.apache.poi.ddf.EscherDgRecord;
import org.apache.poi.ddf.EscherDggRecord;
import org.apache.poi.util.Removal;
/**
@ -62,42 +61,6 @@ public class DrawingManager2 {
return dg;
}
/**
* Allocates new shape id for the drawing group id.
*
* @param drawingGroupId the drawing group id
*
* @return a new shape id
*
* @deprecated in POI 3.17-beta2, use allocateShapeId(EscherDgRecord)
*/
@Deprecated
@Removal(version="4.0")
public int allocateShapeId(short drawingGroupId) {
for (EscherDgRecord dg : drawingGroups) {
if (dg.getDrawingGroupId() == drawingGroupId) {
return allocateShapeId(dg);
}
}
throw new IllegalStateException("Drawing group id "+drawingGroupId+" doesn't exist.");
}
/**
* Allocates new shape id for the drawing group
*
* @param drawingGroupId the drawing group id
* @param dg the EscherDgRecord which receives the new shape
*
* @return a new shape id.
*
* @deprecated in POI 3.17-beta2, use allocateShapeId(EscherDgRecord)
*/
@Deprecated
@Removal(version="4.0")
public int allocateShapeId(short drawingGroupId, EscherDgRecord dg) {
return allocateShapeId(dg);
}
/**
* Allocates new shape id for the drawing group
*

View File

@ -150,20 +150,6 @@ public abstract class POIXMLDocument extends POIXMLDocumentPart implements Close
return properties;
}
/**
* Get the document's embedded files.
*
* @return the document's embedded files
*
* @throws OpenXML4JException if the embedded parts can't be determined
* @deprecated use <code>getAllEmbeddedParts</code> instead
*/
@Deprecated
@Removal(version = "4.2")
public List<PackagePart> getAllEmbedds() throws OpenXML4JException {
return getAllEmbeddedParts();
}
/**
* Get the document's embedded files.
*

View File

@ -16,6 +16,7 @@
==================================================================== */
package org.apache.poi.hssf.usermodel;
import org.apache.poi.ddf.*;
import org.apache.poi.hssf.model.DrawingManager2;
import org.apache.poi.hssf.model.InternalSheet;
@ -37,20 +38,10 @@ public class HSSFTestHelper {
super(null);
}
@Override
public int allocateShapeId(short drawingGroupId) {
return 1025; //Mock value
}
@Override
public int allocateShapeId(EscherDgRecord dg) {
return 1025;
}
@Override
public int allocateShapeId(short drawingGroupId, EscherDgRecord dg) {
return 1025;
}
@Override
public EscherDgRecord createDgRecord()