<!--
{
  "availability" : [
    "iOS: 5.0.0 -",
    "iPadOS: 5.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.14.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "GSS",
  "identifier" : "/documentation/GSS/gss_OID_desc_struct/init(length:elements:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "GSS"
    ],
    "preciseIdentifier" : "s:So19gss_OID_desc_structV6length8elementsABs6UInt32V_SvSgtcfc"
  },
  "title" : "init(length:elements:)"
}
-->

# init(length:elements:)

Initialize a new object identifier with the given array of octets.

```
init(length: OM_uint32, elements: UnsafeMutableRawPointer!)
```

## Parameters

`length`

The number of octets in the `elements` array.

`elements`

A pointer to the beginning of an array of octets of the specified length that represent the object identifier.

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)