XCServerCoreData 5.3.3

XCServerCoreData 5.3.3

TestsTested
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Dec 2017
SwiftSwift Version 4.0
SPMSupports SPM

Maintained by Richard Piazza.


Downloads

Total158
Week0
Month0

Installs

Apps4
Test Targets2
powered by Segment

GitHub

Stars1
Watchers1
Forks0
Issues0
Contributors1
Pull Requests0

Code

Files55
LOCLines of Code 2,371


 
Depends on:
CodeQuickKit~> 6.0
XCServerAPI~> 4.2
 

XCServerCoreData

Version
Platform

An CoreData Storage framework for working with Xcode Server.
Depends on the XCServerAPI project for interacting with the API.

XCServerCoreData.swift

Provided the main interaction with the XCServerCoreData framework.
Using all defaults:

// Reference the MOC
let moc = XCServerCoreData.sharedInstance.managedObjectContext

// Create a server reference
guard let server = XcodeServer(managedObjectContext: moc, fqdn: "test.example.com") else {
    fatalError()
}

// Retrieve the bots
XCServerCoreData.syncBots(forXcodeServer: server, completion: { (error) in
    if let e = error {
        // Handle the error
        return
    }
    
    // Perform post sync actions; A save() will have been performed on the MOC.
})

Other methods for the XcodeServer entity include:

XCServerCoreData.ping(xcodeServer:, completion:)
XCServerCoreData.syncVersionData(xcodeServer:, completion:)

Methods for the Bot entity include:

XCServerCoreData.syncBot(bot:, completion:)
XCServerCoreData.syncStats(bot:, completion:)
XCServerCoreData.triggerIntegration(bot:, completion:)
XCServerCoreData.syncIntegrations(bot:, completion:)

Methods for the Integration entity include:

XCServerCoreData.syncIntegration(integration:, completion:)
XCServerCoreData.syncCommits(forIntegration:, completion:)
XCServerCoreData.syncIssues(forIntegration:, completion:)