---
Product: Aspose.3D
Platform: typescript
Page Type: reference
Canonical URL: https://reference.aspose.org/3d/typescript/StlFormat
---

# StlFormat

## Overview

`StlFormat` is the built-in format handler for STL (.stl) files in Aspose.3D for TypeScript. It inherits from `FileFormat` and exposes factory methods that create the detector, importer, and exporter for this format. When a `Scene` loads or saves a `.stl` file, it delegates all I/O work to this class internally. The class also provides access to default `StlFormatLoadOptions` and `StlFormatSaveOptions` instances that control parsing and serialisation behaviour for every read and write operation.

## Description

`StlFormat` is a class in the Aspose.3D FOSS library for TypeScript that exposes 7 methods and 8 properties for programmatic use. It extends `FileFormat`, inheriting shared functionality from its parent type.

Core capabilities include: `string`; `string[]`; `string`. These operations enable developers to integrate stlformat functionality directly into TypeScript applications.

The class also provides the `extension` property (returns the default file extension for stl format), the `extensions` property (returns an array of supported stl file extensions), the `contentType` property (stores the mime type associated with stl files).

Instances are created through a single constructor that initializes the object with default values.

## Properties

| Name | Type | Access | Description |
|------|------|--------|-------------|
| `extension` | `string` | Read | Returns the default file extension for STL format |
| `extensions` | `string[]` | Read | Returns an array of supported STL file extensions |
| `contentType` | `string` | Read | Stores the MIME type associated with STL files |
| `fileFormatType` | `any` | Read | Identifies the internal format type for STL |
| `version` | `string` | Read | Contains the library version string for the STL format support |
| `canExport` | `boolean` | Read | Is a boolean indicating export capability for STL |
| `canImport` | `boolean` | Read | Is a boolean indicating import capability for STL |
| `formats` | `any[]` | Read | Lists available format descriptors related to STL |

## Methods

| Signature | Description |
|-----------|-------------|
| `canImport()` → `boolean` | Is a boolean indicating import capability for STL |
| `canExport()` → `boolean` | Is a boolean indicating export capability for STL |
| `extension()` → `string` | Returns the default file extension for STL format |
| `extensions()` → `string[]` | Returns an array of supported STL file extensions |
| `constructor()` |  |
| `getInstance()` → `StlFormat` |  |
| `createLoadOptions()` → `StlLoadOptions` | Creates a StlLoadOptions object for importing STL files |
| `createSaveOptions()` → `StlSaveOptions` | Creates a StlSaveOptions object for exporting STL files |

## See Also

- [Aspose.3D — Enterprise API Reference](https://reference.aspose.com/3d/)