Package com.odb.core

Examples of com.odb.core.SubscriberDataSource


  /* (non-Javadoc)
   * @see org.springframework.jdbc.core.ResultSetExtractor#extractData(java.sql.ResultSet)
   */
  public SubscriberDataSource extractData(ResultSet rs) throws SQLException, DataAccessException {
    SubscriberDataSource sds= null;
    if(rs.next()){
      sds = new SubscriberDataSource();
      sds.setDataSourceID(rs.getString("DATASOURCE_ID"));
      sds.setGraphID(rs.getString("GRAPH_ID"));
      sds.setSubscriberDataSourceID(rs.getString("SUBSCRIBER_DATASOURCE_ID"));
      sds.setSubscriberID(rs.getString("SUBSCRIBER_ID"));
      sds.setSubscriberViewConfiguration(new SubscriberViewConfiguration(rs.getString("SUBSCRIBER_ID"), rs.getString("VIEW_LOCATION_ID"), rs.getString("SUBSCRIBER_DATASOURCE_ID")));
      sds.setGraphInfo(new GraphInfo(rs.getString("GRAPH_ID"), rs.getString("GRAPH_NAME"), rs.getString("GRAPH_TYPE")));
    }
    return sds;
  }
View Full Code Here


   * @param viewLocationID
   *            the view location id
   * @return the subscriber data source by
   */
  public SubscriberDataSource getSubscriberDataSourceBy(String subscriberId, String viewLocationID) {
    SubscriberDataSource sds = null;
    try {
      sds = odbDAO.getSubscriberDataSourceBy(subscriberId, viewLocationID);
    } catch (SQLException e) {
      log.error("Getting Subscriber DataSource failed for subscriberID:" + subscriberId + " SubsrciptionID:" + viewLocationID + e);
    }
View Full Code Here

  public SubscriberDataSource getSubscriberDataSourceBy(String subscriberId, String viewLocationID) throws SQLException {
    String sql = "SELECT SDS.* , SVC.VIEW_LOCATION_ID, GC.GRAPH_NAME, GC.GRAPH_TYPE FROM ODB_SUB_DATASOURCES SDS, ODB_SUB_VIEW_CONFIG SVC, ODB_GRAPH_CONFIG GC WHERE SDS.SUBSCRIBER_DATASOURCE_ID=SVC.SUBSCRIBER_DATASOURCE_ID AND SDS.GRAPH_ID=GC.GRAPH_ID AND SDS.SUBSCRIBER_ID=:subscriberID AND SVC.VIEW_LOCATION_ID=:viewLocationID";
    Map<String, String> paramMap = new HashMap<String, String>();
    paramMap.put("subscriberID", subscriberId);
    paramMap.put("viewLocationID", viewLocationID);
    SubscriberDataSource sds = jdbcTemp.query(sql, paramMap, new SubscriberDataSourceoResultSetExtractor());
    log.debug("SubscriberDataSource" + sds);
    return sds;
  }
View Full Code Here

TOP

Related Classes of com.odb.core.SubscriberDataSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.