Skip to content

Incorporating TCMXMLWriter.h/.m in a Swift project #5

@jrubl9427

Description

@jrubl9427

When initializing a writer in C TCMXMLWriter *writer = [[TCMXMLWriter alloc] initWithOptions:TCMXMLWriterOptionPrettyPrinted]; was used which worked as expected.

In Swift var writer = TCMXMLWriter(options: TCMXMLWriterOptionPrettyPrinted) will not compile and gives error "Cannot invoke 'init' with an argument list of type '(options: Int)'

A workaround is to initialize with var writer = TCMXMLWriter(options: 1), this worked as expected

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions