Code Monkey home page Code Monkey logo

Comments (2)

Ciantic avatar Ciantic commented on July 20, 2024

Okay, I figured I can just do:

 let mut status_list = cast_device
                .media
                .get_status(app.transport_id.as_str(), None)
                .unwrap()
                .entries
let status = status_list.remove(0);

However now I have problem that Serialize and Deserialize is not implemented, but that is a different issue altogether.

from rust-cast.

azasypkin avatar azasypkin commented on July 20, 2024

@Ciantic glad that you found the crate useful!

I'm pretty new to Rust, but I think the StatusEntry and others could derive the Copy and Clone too so one could make helpers.

Unfortunately it wouldn't be easy/correct to add Copy everywhere since many of the structures use String fields (well, yeah, my first Rust project 🙈) and String obviously doesn't implement Copy automatically. Having said that I've just added Clone wherever it makes sense and Copy where it's possible and published new version (additionally switched crate to 2018 edition and upgraded dependencies).

I don't have a TV/HDMI display/enough time these days to work on this crate actively and happy to accept any improvements or fixes you may come up with!

from rust-cast.

Related Issues (16)

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.