• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
(dirty solved): NSDates, NSTimestamps and the Java-bridge
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

(dirty solved): NSDates, NSTimestamps and the Java-bridge


  • Subject: (dirty solved): NSDates, NSTimestamps and the Java-bridge
  • From: Ricardo Strausz <email@hidden>
  • Date: Wed, 14 May 2003 14:49:09 -0500

Gracias Joaquin!
Thanks Art, Seejo, Dirk!

I'd found a solution... dirty but it works.
Basically I have to assgin the qualifier in the Java side.
I hope Apple is doing something to get better Cocoa/EO... and the
Java-Bridge!

Here is the code:

- (NSArray*)facturasDe:(id)eo desde:(NSCalendarDate*)desde
{
     [desde setCalendarFormat:@"%d %m %Y"];

     id nst = [Util nst:[desde description]]; //this is an NSTimestamp
created by Util.java

     [Util setAuxiliaryQualifierTo:[dgFacturas dataSource]:eo:nst];
     [dgFacturas fetch:self];

     return [dgFacturas displayedObjects];
}


     public NSTimestamp nst(String dateString){
         NSTimestampFormatter formatter=new NSTimestampFormatter("%d %m
%Y");
         ParsePosition pp = new ParsePosition(0);
         NSTimestamp
myNSTimestamp=(NSTimestamp)formatter.parseObject(dateString,pp);

         return myNSTimestamp;
     }

     public void setAuxiliaryQualifierTo(EODatabaseDataSource ds,
Facturas eo, NSTimestamp nst){
         NSMutableArray nsma = new NSMutableArray();
         nsma.addObject(eo.folio());
         nsma.addObject(nst);

         EOQualifier eoq =
EOQualifier.qualifierWithQualifierFormat("cliente=%@ and fecha>=%@ and
estado>0",nsma);
         ds.setAuxiliaryQualifier(eoq);
     }



Dino
http://homepage.mac.com/strausz
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: NSDates, NSTimestamps and the Java-bridge (From: Ricardo Strausz <email@hidden>)

  • Prev by Date: Attempt to insert null key into a com.webobjects.foundation.NSMutableDictionary
  • Next by Date: Re: NSDates, NSTimestamps and the Java-bridge
  • Previous by thread: Re: NSDates, NSTimestamps and the Java-bridge
  • Next by thread: Re: NSDates, NSTimestamps and the Java-bridge
  • Index(es):
    • Date
    • Thread