BACK-PORTING可以在Jellybean API 16中使用PDFDocument(API 19)吗? [英] BACK-PORTING can use PDFDocument (API 19) in jellybean API 16?

查看:82
本文介绍了BACK-PORTING可以在Jellybean API 16中使用PDFDocument(API 19)吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Android 4.4.2 (API19)进行编译,但是在Android 4.1.1 API 16上运行. 是否有Android支持库等,所以我可以在Jellybean API 16中使用PdfDocument.java(API 19)?

I'm compiling using Android 4.4.2 (API19) but running on Android 4.1.1 API 16. Is there an Android support library, or something, so I can use PdfDocument.java (API 19) in Jellybean API 16?

代码:

import android.graphics.pdf.PdfDocument;
import android.graphics.pdf.PdfDocument.Page;
import android.graphics.pdf.PdfDocument.PageInfo;

        PdfDocument doc = new PdfDocument();

错误日志:

07-22 14:58:41.869: E/dalvikvm(4165): Could not find class
'android.graphics.pdf.PdfDocument', referenced from method com.example.html2pdf.Html2pdfActivity.button1onClick

07-22 14:59:33.965: E/AndroidRuntime(4165): Caused by: java.lang.NoClassDefFoundError: android.graphics.pdf.PdfDocument

我可以打包所需的系统库并将其放入我的应用程序吗? (或以某种方式绕过/重新定位系统调用)?

推荐答案

不,抱歉,Google尚未发布PdfDocument或任何与Android 4.4+打印API相关的任何内容的反向端口.

No, sorry, Google has not published a backport of PdfDocument or pretty much anything related to the Android 4.4+ printing APIs.

这篇关于BACK-PORTING可以在Jellybean API 16中使用PDFDocument(API 19)吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆