Need documentation for classes l0t, l0n and l2if in package com.aspose.pdf.internal

Hello,
I am trying to update a code base to now use the latest version of Aspose. We were on 19.7. Everything went very smooth, except I am running across some classes that appear to have little to no documentation online like l0t, l0n and l2if (to name some).

Here is some of the code…

// using internal aspose code to save the fringe because it has no public getter/setter
l0n ary = new l0n(annotationObject.getEngineDict(), new l0t[]{new l1u(fringe[0]), new l1u(fringe[1]), new l1u(fringe[2]), new l1u(fringe[3])});|
annotationObject.getEngineDict().lI(RD, ary);|

Any help would be greatly appreciated.

Thank you,

Adam

@adecatur

These must be internal classes which we hide and expose their interfaces for public usages. Can you please share complete code snippet instead of a chunk from it so that we may know how you were using them and perform investigation to provide you an alternate for it.

Awesome, sounds great.

Snippet #1:
Note: annotationObject is a MarkupAnnotation. annotation is a class of ours.

//manually setting the creation date in the xfdf using internal aspose methods
		if(annotation.getCreationDate() != null) {
			l2if engineDict = new l2if(annotationObject.getEngineDict());
			lf.lI(l3t.lI(annotation.getCreationDate()).l1y(), engineDict);
			annotationObject.getEngineDict().lI("CreationDate", engineDict);
		} else {
			l2if engineDict = new l2if(annotationObject.getEngineDict());
			lf.lI(l3t.lI(annotation.getModifyDate()).l1y(), engineDict);
			annotationObject.getEngineDict().lI("CreationDate", engineDict);
			logger.warn("There is no creation date on annotation. Replaced date with the last modified date of the pdf.");
		}

Snippet #2:

		FreeTextAnnotation annotationObject = new FreeTextAnnotation(curPage, markupRectangle, new DefaultAppearance());
		annotationObject = (FreeTextAnnotation) burnInFreeTextFields(annotation, annotationObject, curPage, markupRectangle);

		// PDFNAME_CL refers to the arrow (callout) data of the callout annotation
		List<Point> calloutList = new ArrayList<>();
		float[] callout = annotation.getCallout();
		for (int i = 0; i < callout.length; i = i+2) {
			calloutList.add(new Point(callout[i], callout[i+1]));
		}

		float[] fringe = annotation.getFringe();

		annotationObject.setCallout(calloutList.toArray(calloutList.toArray(new Point[calloutList.size()])));

		// using internal aspose code to save the fringe because it has no public getter/setter
		l0n ary = new l0n(annotationObject.getEngineDict(), new l0t[]{new l1u(fringe[0]), new l1u(fringe[1]), new l1u(fringe[2]), new l1u(fringe[3])});
		annotationObject.getEngineDict().lI("RD", ary);

Snippet #3:
Note: annotationObject is a TextAnnotation

annotationObject.getEngineDict().lI("StateModel", new l2if(annotationObject.getEngineDict(), annotation.getStateModel()));

Snippet #4:

protected float[] getCalloutFringe(FreeTextAnnotation freeA) {
		float[] fringe = new float[4];
		for(int i=0; i < 4; i++) {
			fringe[i] = (float) freeA.getEngineDict().lf("RD").l5t().lI(i).l5h().lu();
		}
		return fringe;
	}

@adecatur

We are collecting related information and will get back to you shortly.

1 Like

Any update here?

@adecatur

This can take a little longer than expected because we need to check change logs for the API versions. Therefore, a dedicated ticket as PDFJAVA-43871 has been logged in our issue tracking system. We will check it in details and let you know as soon as it is resolved. Please be patient and spare us some time.

Sounds good. Thank you for the update.

I think I resolved most of these. I think I just need help with how to convert code snippet #2 and #4 by using something like FreeTextAnnotation.getCallout().

@adecatur

We are afraid that the ticket could not get resolved yet due to other issues in the queue. We will surely inform you once we make some progress and have feedback for you. Please spare us little time.

Ok, sounds good