# `GSLayer propertyListValueFormat:error:`

*Instance Method*

A property-list representation for the specified Glyphs file format version.

## Declaration

```swift
func propertyListValue(format: GSFormatVersion) throws -> [String : Any]
```

```objc
- (NSDictionary<NSString *,id> *) propertyListValueFormat:(GSFormatVersion) format error:(NSError **) error;
```

```python
propertyListValueFormat_error_(format: GSFormatVersion) -> tuple[dict[str, object], NSError]
```

## Parameters

- `format` — The Glyphs file format version for which to encode the layer.
- `error` — On output, a pointer to an error object that describes why the method failed, or `nil` if no error occurred. If you are not interested in the error information, pass `nil` for this parameter.

## See Also

### Encoding

- [`GSLayer saveToFile:format:context:error:`](/Core/GlyphsCore/GSLayer/saveToFile:format:context:error:) — Writes the layer in the specified Glyphs file format.
- [`GSLayer attributesDict:`](/Core/GlyphsCore/GSLayer/attributesDict:) — An attribute representation for the specified Glyphs file format version.
- [`GSLayer.readBuffer`](/Core/GlyphsCore/GSLayer/readBuffer) — Values deferred until the layer can complete format-dependent decoding.
- [`GSLayer setReadBuffer:forKey:`](/Core/GlyphsCore/GSLayer/setReadBuffer:forKey:) — Stores a value for format-dependent decoding after the layer hierarchy is available.
- [`GSLayer postRead:format:`](/Core/GlyphsCore/GSLayer/postRead:format:) — Completes format-dependent decoding after the layer has been attached to its object hierarchy.
- [`GSLayer layerDataFromDict:format:error:`](/Core/GlyphsCore/GSLayer/layerDataFromDict:format:error:) — Encodes layer elements as Glyphs property-list data.

