GithubHelp home page GithubHelp logo

marijnbetman / prepr Goto Github PK

View Code? Open in Web Editor NEW

This project forked from vpro/prepr

0.0 0.0 0.0 725 KB

Domain classes and client for the radiomanager API 'prepr' https://developers.prepr.io/

License: GNU General Public License v3.0

Java 100.00%

prepr's Introduction

prepr

Domain classes and client for https://developers.prepr.io/ ('prepr')

Build Status Maven Central snapshots javadoc

This was created because POMS sychronizes data from prepr for radio related data of the dutch public broadcasters

Example code:

   PreprRepositoryImpl impl = new PreprRepositoryImpl(
       Prepr.
        .builder()
        .clientId("<your client id>")
        .clientSecret("<your client secret>")
        .build();



    public void getSchedule() throws IOException, URISyntaxException {
        log.info("schedule: {}",
            impl.getTimelines().getSchedule(UUID.fromString("59ad94c1-7dec-4ea0-a9b4-b9eb4b6cfb16") // Channel.RAD5)
                , LocalDate.of(2018, 5, 7), LocalDate.of(2018, 5, 8))
        );
    }

It is also possible to instantiate a bunch of repositories using spring

  <bean class="nl.vpro.io.prepr.spring.SpringPreprRepositoriesConfiguration">
    <constructor-arg value="media.properties" />
  </bean>

This will create PreprRepositoryImpl beans prepr.<channel>, and also one instance of PreprRepositories

Something similar can also be accomplished without spring

nl.vpro.io.prepr.StandalonePreprRepositories.fromMap()

(note that @CacheResult is not working then.)

Testing

There are junit test in the normal spots. Some things are in '*ITest' classes. These are currently mainly used to try things out. They find credentials in ${USER.HOME}/conf/prepr.properties. We don’t have proper integration tests yet.

prepr's People

Contributors

mihxil 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.