• 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
Re: Code completion for a component's binding
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Code completion for a component's binding


  • Subject: Re: Code completion for a component's binding
  • From: Johann Werner <email@hidden>
  • Date: Fri, 16 Nov 2012 07:57:58 +0100

Am 16.11.2012 um 00:52 schrieb Michael Sharp <email@hidden>:

> They seem to be defined in code in WOLips. The possible values for "defaults" here:
>
> org.objectstyle.wolips.bindings.api.IApiBinding
>
> public static final String[] ALL_DEFAULTS = new String[] { "Undefined", IApiBinding.ACTIONS_DEFAULT, "Boolean", "YES/NO", "Date Format Strings", "Number Format Strings", "MIME Types", "Direct Actions", "Direct Action Classes", "Page Names", "Frameworks", "Resources" };
>
> And dealt with here org.objectstyle.wolips.bindings.api.ApiUtils
>
> eg
>
> if ("Date Format Strings".equals(defaultsName)) {
>       validValues.add("\"%m/%d/%y\"");
>       validValues.add("\"%B %d, %Y\"");
>       validValues.add("\"%b %d, %Y\"");
>       validValues.add("\"%A, %B %d, %Y\"");
>       validValues.add("\"%A, %b %d, %Y\"");
>       validValues.add("\"%d.%m.%y\"");
>       validValues.add("\"%d %B %y\"");
>       validValues.add("\"%d %b %y\"");
>       validValues.add("\"%A %d %B %Y\"");
>       validValues.add("\"%A %d %b %Y\"");
>       validValues.add("\"%x\"");
>       validValues.add("\"%H:%M:%S\"");
>       validValues.add("\"%I:%M:%S %p\"");
>       validValues.add("\"%H:%M\"");
>       validValues.add("\"%I:%M %p\"");
>       validValues.add("\"%X\"");
>     }

That should probably be changed to SimpleDateFormat strings as NSTimestampFormatter understands those too and is deprecated.

>
>
> Sharpy
>
> On 16/11/2012, at 9:41 AM, Michael Sharp <email@hidden> wrote:
>
>> I've wondered myself, so I just had a sniff around some API files.
>>
>> e.g. ERXEditDateJavascript.api contains the following:
>> 	<binding name="dateformat" defaults="Date Format Strings"/>
>>
>>  … and offers the right hand side completion of exactly that in the wod editor - date format strings.  Changing this to:
>>
>> 	<binding name="dateformat" defaults="Numbers Format Strings"/>
>>
>> has the expected effect - number format completion choices.
>>
>> I guess these come from somewhere in WOLips, not sure if they're configurable. Will keep digging.
>>
>>
>> Sharpy..
>>
>>
>> On 16/11/2012, at 8:14 AM, Johnny Miller <email@hidden> wrote:
>>
>>> Hi,
>>>
>>> I would like to add code completion to a component the way in WOString it will give you a list of suggested number or date formats for the respective binding.
>>>
>>> How do you declare this in your component?
>>>
>>> Thanks in advance,
>>>
>>> Aloha,
>>> Mr. Johnny Miller
>>> Web Development Manager
>>> Kahalawai Media Company
>>> Lahaina, HI 96761
>>> tel: (808) 661-7962 | mobile: (808) 283-0791
>>> website | e-mail
>>>
>>> _______________________________________________
>>> Do not post admin requests to the list. They will be ignored.
>>> Webobjects-dev mailing list      (email@hidden)
>>> Help/Unsubscribe/Update your Subscription:
>>>
>>> This email sent to email@hidden
>>


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


References: 
 >Code completion for a component's binding (From: Johnny Miller <email@hidden>)

  • Prev by Date: Re: Code completion for a component's binding
  • Next by Date: Re: Code completion for a component's binding
  • Previous by thread: Re: Code completion for a component's binding
  • Next by thread: Re: Code completion for a component's binding
  • Index(es):
    • Date
    • Thread