Skip to content

Commit

Permalink
Merge pull request #74 from transifex/fix/documentation
Browse files Browse the repository at this point in the history
Improve documentation
  • Loading branch information
Nikos Vasileiou authored Jul 9, 2024
2 parents 3ba06d9 + d715588 commit 736e444
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The SDK can fetch translations over the air (OTA), manages an internal cache of
and works seamlessly without requiring any changes in the source code of the app by the
developer.

Both Objective-C and Swift projects are supported.
Both Objective-C and Swift projects are supported. SwiftUI is also supported as of v2.0.3.

The package is built using Swift 5.3, as it currently requires a bundled resource to be
present in the package (feature introduced in version 5.3).
Expand Down
10 changes: 10 additions & 0 deletions Sources/Transifex/CDSHandler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,16 @@ public final class TXPushConfiguration : NSObject {
@objc
public let dryRun: Bool

/// Initialize the push configuration object with the provided parameters.
///
/// Refer to the documentation of each property for default values and more information.
///
/// - Parameters:
/// - purge: The purge content boolean flag.
/// - overrideTags: The override tags boolean flag.
/// - overrideOccurrences: The override occurrences boolean flag.
/// - keepTranslations: The keep translations boolean flag.
/// - dryRun: The dry run boolean flag.
@objc
public init(purge: Bool = false,
overrideTags: Bool = false,
Expand Down
6 changes: 3 additions & 3 deletions Sources/Transifex/Plurals.swift
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,7 @@ final class XMLPluralParser: NSObject {
}

extension XMLPluralParser : XMLParserDelegate {
public func parser(_ parser: XMLParser, didStartElement elementName: String,
func parser(_ parser: XMLParser, didStartElement elementName: String,
namespaceURI: String?, qualifiedName qName: String?,
attributes attributeDict: [String : String] = [:]) {
guard elementName == TXNative.CDS_XML_TAG_NAME,
Expand All @@ -569,7 +569,7 @@ extension XMLPluralParser : XMLParserDelegate {
pendingString = ""
}

public func parser(_ parser: XMLParser, didEndElement elementName: String,
func parser(_ parser: XMLParser, didEndElement elementName: String,
namespaceURI: String?, qualifiedName qName: String?) {
guard let cdsUnitID = pendingCDSUnitID else {
return
Expand All @@ -579,7 +579,7 @@ extension XMLPluralParser : XMLParserDelegate {
pendingString = ""
}

public func parser(_ parser: XMLParser, foundCharacters string: String) {
func parser(_ parser: XMLParser, foundCharacters string: String) {
guard let _ = pendingCDSUnitID else {
return
}
Expand Down

0 comments on commit 736e444

Please sign in to comment.