Coder Social home page Coder Social logo

vicxruiz / host.swift Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rjstelling/host.swift

0.0 1.0 0.0 408 KB

*Host.swift is no longer maintained*, please use Hostess.swift: https://github.com/rjstelling/Hostess.swift. A Swift implementation of NSHost that works on iOS, OS X and tvOS. Host.swift is safe to use in a framework because it does not require a bridging header.

Home Page: https://github.com/rjstelling/Hostess.swift

License: Other

Objective-C 5.11% Swift 94.89%

host.swift's Introduction

#Host.swift is no longer maintained

Please use Hostess.swift: https://github.com/rjstelling/Hostess.swift

Host.swift

Swift ![Platform](https://img.shields.io/badge/Platform-iOS, macOS & tvOS-lightgrey.svg?style=flat) Carthage compatible License

A Swift implementation of NSHost that works on iOS, OS X and tvOS.

Host.swift is safe to use in a framework because it does not require a bridging header.

##Motivation

Host.swift was created because NSHost is unavailable on iOS and CFHost does not offer the full functionality of it OS X counterpart.

In addition, those developers hoping for a pure-Swift solution were out of luck without using a bridging header.

Host.swift does not use a bridging header, so is safe to use in Framework development. It is 100% Swift and tries to maintain as much type safety as the low level networking C API will allow.

Example

let host = Host()
let deviceIP = host.addresses.first
print("IP: \(deviceIP)") // Will print a dot-separated IP address, e.g: 17.24.2.55

host.swift's People

Contributors

albinekcom avatar rjstelling avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.