GithubHelp home page GithubHelp logo

comments-of-my-blog's People

Watchers

 avatar

comments-of-my-blog's Issues

[Java]使用java创建一个EPUB格式的文件

https://blog.fortruth.link/2024/03/java_create-an-epub-format-file-using-java/

Your browser does not support the audio tag.
1、导包 如果用的是maven,在pom.xml中这么写:

4.0.0 org.example tools 1.0-SNAPSHOT 17 17 com.positiondev.epublib epublib-core 3.1

2、使用java生成EPUB格式的示例代码: import nl.siegmann.epublib.domain.Author; import nl.siegmann.epublib.domain.Book; import nl.siegmann.epublib.domain.Resource; import nl.siegmann.epublib.epub.EpubWriter; import java.io.FileOutputStream; import java.io.IOException; /** * 使用java创建Epub格式文件的例子。 */ public class CreateEpub { // 标题 private static final String TITLE = "标题"; // 作者 private static final String AUTHOR = "作者"; // 编码格式 private static final String CHARSET = "UTF-8"; public static void main(String[] args) { try { // 创建一个新的 EPUB 文档 Book book = new Book(); // 设置元数据 book.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.