Package de.willuhn.util

Examples of de.willuhn.util.TypedProperties


   * @return Maximale Anzahl der Zeilen.
   * @throws RemoteException
   */
  public final static int getMaxUsageUeb(Konto konto) throws RemoteException
  {
    TypedProperties bpd = DBPropertyUtil.getBPD(konto,DBPropertyUtil.BPD_QUERY_UEB);
    return bpd.getInt("maxusage",HBCIProperties.HBCI_TRANSFER_USAGE_MAXNUM);
  }
View Full Code Here


   * Die Funktion liefert nie NULL sondern hoechstens leere Properties.
   * @throws RemoteException
   */
  public static TypedProperties getBPD(Konto konto, String query) throws RemoteException
  {
    final TypedProperties props = new HBCITypedProperties();

    // Konto angegeben?
    if (konto == null || query == null || query.length() == 0)
      return props;
   
    // Kundennummer korrekt?
    String kd = konto.getKundennummer();
    if (kd == null || kd.length() == 0 || !kd.trim().matches("[0-9a-zA-Z]{1,30}"))
      return props;

    // Wir haengen noch unseren Prefix vorn dran. Der wurde vom Callback hinzugefuegt
    query = "bpd." + kd.trim() + "." + query;

    // Wir sortieren aufsteigend, da es pro BPD-Set (z.Bsp. in "%UebPar%") mehrere
    // gibt (jeweils pro Segment-Version). HBCI4Java nimmt bei Geschaeftsvorfaellen
    // immer die hoechste verfuegbare Segment-Version. Also machen wir das hier auch
    Settings.getDBService().execute("select name,content from property where name like ? order by name",new String[]{query},new ResultSetExtractor()
    {
      public Object extract(ResultSet rs) throws RemoteException, SQLException
      {
        while (rs.next())
        {
          String name  = rs.getString(1);
          String value = rs.getString(2);

          if (name == null || value == null) continue;
         
          // Wir trimmen noch den Prefix aus dem Namen raus
          name = name.substring(name.lastIndexOf('.')+1);
          props.put(name,value);
        }
        return null;
      }
    });
   
View Full Code Here

   
    SepaDauerauftrag auftrag = this.getTransfer();
    if (auftrag.isActive())
      this.bpd = DBPropertyUtil.getBPD(auftrag.getKonto(),DBPropertyUtil.BPD_QUERY_SEPADAUER_EDIT);
    else
      this.bpd = new TypedProperties(); // Der Auftrag ist noch nicht aktiv - dann gibt es noch keine Einschraenkungen
   
    return this.bpd;
  }
View Full Code Here

   
    Dauerauftrag auftrag = (Dauerauftrag) this.getTransfer();
    if (auftrag.isActive())
      this.bpd = DBPropertyUtil.getBPD(auftrag.getKonto(),DBPropertyUtil.BPD_QUERY_DAUER_EDIT);
    else
      this.bpd = new TypedProperties(); // Der Auftrag ist noch nicht aktiv - dann gibt es noch keine Einschraenkungen
   
    return this.bpd;
  }
View Full Code Here

TOP

Related Classes of de.willuhn.util.TypedProperties

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.