Skip to content

azawawi/swift-zmq

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

81 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ZMQ - ZeroMQ Swift bindings

Swift Platform License

This package provides Swift API bindings for the famous ZeroMQ library.

Note: At the moment, please consider the project experimental.

ZeroMQ (also spelled ØMQ, 0MQ or ZMQ) is a high-performance asynchronous messaging library, aimed at use in distributed or concurrent applications. It provides a message queue, but unlike message-oriented middleware, a ZeroMQ system can run without a dedicated message broker. The library's API is designed to resemble that of Berkeley sockets.

Project Goals

  • Provide an easy to use API to ZeroMQ using Swift language idioms
  • Provide up to date ZeroMQ binaries for iOS and the macOS plaforms
  • Support linux and macOS plaforms for server-side projects
  • Support iOS platform for mobile app projects

Example

import ZMQ

let (major, minor, patch) = ZMQ.version
print("ZeroMQ library version is \(major).\(minor).\(patch)")

More examples can be found in the examples github repository.

Usage

Your Package.swift should be something like the following code to be able to use this package:

import PackageDescription

let package = Package(
    name: "YourPackageName",
    dependencies: [
        .Package(
            url          : "https://github.com/azawawi/swift-zmq.git",
            majorVersion : 0,
            minor        : 4
        )
    ]
)

Installation

Please check LibZMQ for installation instructions.

Testing

To run tests, please type:

$ swift test

Troubleshooting

  • You may get the following error after a swift build:

error: The dependency graph could not be satisfied because an update to...


    To resolve it, please run:

    ```
swift build --clean dist
swift build

See Also

Author

Ahmad M. Zawawi

License

MIT License

About

ZeroMQ Swift bindings

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages