5 maj 2008 kl. 13.52 skrev Mike Schrag:
I have been using your excellent class ModRewriteWOHyperlink. When trying to get it to work in WebObjects 5.4 it stumbled on computeQueryDictionaryInContext which of course is in a private framework. Has anyone gotten this to work in 5.4? Should I use another method for my rewrite needs?
The signature of this method changed in 5.4 ... If I recall correctly, in 5.4 it takes a boolean "secure" in front of the WOContext param?

Yes according to eclipse it changed from
computeQueryDictionaryInContext(WOAssociation, WOAssociation, WOAssociation, boolean, NSDictionary, WOContext) to computeQueryDictionaryInContext(String, WOAssociation, NSDictionary<String,WOAssociation>, WOContext)

Which is used by ModRewriteWOHyperlink by this call:
NSDictionary queryDict = computeQueryDictionaryInContext(_actionClass, _directActionName, _queryDictionary, _actionClass != null, _otherQueryAssociations, wocontext);

The arguments are initialized in the constructor like this:

public ModRewriteWOHyperlink(String s, NSDictionary nsdictionary, WOElement woelement)
    {
        super("a", nsdictionary, woelement);
//System.out.println( "ModRewriteWOHyperlink Constructor" );
_otherQueryAssociations = _NSDictionaryUtilities.extractObjectsForKeysWithPrefix(_associations, "?", true); _otherQueryAssociations = _otherQueryAssociations == null || _otherQueryAssociations.count() <= 0 ? null : _otherQueryAssociations; _action = (WOAssociation)_associations.removeObjectForKey("action"); _string = (WOAssociation)_associations.removeObjectForKey("string"); _href = (WOAssociation)_associations.removeObjectForKey("href"); _disabled = (WOAssociation)_associations.removeObjectForKey("disabled"); _queryDictionary = (WOAssociation)_associations.removeObjectForKey("queryDictionary"); _actionClass = (WOAssociation)_associations.removeObjectForKey("actionClass"); _directActionName = (WOAssociation)_associations.removeObjectForKey("directActionName"); _pageName = (WOAssociation)_associations.removeObjectForKey("pageName"); _secure = (WOAssociation)_associations.removeObjectForKey("secure"); _fragmentIdentifier = (WOAssociation)_associations.removeObjectForKey("fragmentIdentifier"); if(_action == null && _href == null && _pageName == null && _directActionName == null && _actionClass == null) throw new WODynamicElementCreationException("<" + getClass().getName() + "> Missing required attribute: 'action' or 'href' or 'pageName' or 'directActionName' or 'actionClass'"); if(_action != null && _href != null || _action != null && _pageName != null || _href != null && _pageName != null || _action != null && _directActionName != null || _href != null && _directActionName != null || _pageName != null && _directActionName != null || _action != null && _actionClass != null) throw new WODynamicElementCreationException("<" + getClass().getName() + "> At least two of these conflicting attributes are present: 'action', 'href', 'pageName', 'directActionName', 'actionClass'.");
        if(_action != null && _action.isValueConstant())
throw new WODynamicElementCreationException("<" + getClass().getName() + "> 'action' is a constant.");
        else
            return;
    }


Since I don't know what the metod does exactly, it is hard to see how to map the arguments...


Any guesses?

Regards
/Fredrik


ms
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/frelin%40timeoff.se

This email sent to [EMAIL PROTECTED]

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to