Begränsningar och API Skillnader

Offentlig API Skillnader

Följande lista (med exempelkodsegment) visar några skillnader mellan Aspose.Cells for Java och Aspose.Cells for Node.js via Java API:er.

Importera bibliotek (paketjämförelser)

Aspose.Cells for Java

 import com.aspose.cells.*;

Aspose.Cells for Node.js via Java

 var aspose = aspose || {};

aspose.cells = require("aspose.cells");

Instantierar en ny arbetsbok

Aspose.Cells for Java

 Workbook excelbook = new Workbook();

Aspose.Cells for Node.js via Java

 var excelbook = new aspose.cells.Workbook();

Uppräkningar eller konstanter

Aspose.Cells for Java

 arc2.getLineFormat().setDashStyle(MsoLineDashStyle.SOLID);

Aspose.Cells for Node.js via Java

 arc2.getLineFormat().setDashStyle(aspose.cells.MsoLineDashStyle.SOLID);

Strömmande filer

Aspose.Cells for Java

 InputStream inputstream = new FileInputStream(Book1.xlsx);

Workbook workbook = new Workbook(inputstream);

workbook.save(result.xlsx);

Aspose.Cells for Node.js via Java

 var aspose = aspose || {};

aspose.cells = require("aspose.cells");

var fs = require("fs");

var readStream = fs.createReadStream("Book1.xlsx");

aspose.cells.Workbook.createWorkbookFromStream(readStream, function(workbook, err) {

    if (err) {

        console.log("open workbook error");

        return;

    }

   workbook.save('result.xlsx');

    console.log('saved to file');

});

Andra begränsningar för Aspose.Cells for Node.js via Java API jämfört med Aspose.Cells for Java API

  1. Import/export av data från en Array, ArrayList, ResultSet etc. stöds inte.
  2. Utskrift stöds inte.