[Zope3-Users] some basic questions about utility

2006-11-05 Thread Shailesh Kumar
Hi all, 

Could you please clarify some basic doubts about the usage of utilities? Here they are. 

Suppose I have registered a utility using ZCML directive in my web application. 

Is the utility created the moment zope starts up, during the parsing of
my app's ZCML? Can I think of it as a singleton instance? 

Can I do some application specific startups like running some background threads for some tasks in the __init__ of my utility? 


Thank you very much

With regards,
-shailesh

___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


[Zope3-Users] Re: some basic questions about utility

2006-11-05 Thread Philipp von Weitershausen

Shailesh Kumar wrote:
Suppose I have registered a utility using ZCML directive in my web 
application.


Is the utility created the moment zope starts up, during the parsing of 
my app's ZCML? Can I think of it as a singleton instance?


Yes.

Can I do some application specific startups like running some background 
threads for some tasks in the __init__ of my utility?


I suppose so, but why do you need this to happen in threads?

___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


[Zope3-Users] getId in zope3?

2006-11-05 Thread Peter Bengtsson
In Zope2 every object has an 'id' which meant that you can use 
someobject.getId() to find out what name the object is stored under in 
its container.

Is there an equivalent in zope3?
...or am I looking for a solution to a problem that doesn't exist?
--
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] getId in zope3?

2006-11-05 Thread Jim Washington
Peter Bengtsson wrote:
 In Zope2 every object has an 'id' which meant that you can use
 someobject.getId() to find out what name the object is stored under in
 its container.
 Is there an equivalent in zope3?
 ...or am I looking for a solution to a problem that doesn't exist?
Hi, Peter

Have a look at

zope.traversing.api

If you have an older source tree, look for

zope.app.traversing.api

which is deprecated, but OK to use until 3.5.

-Jim Washington
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] getId in zope3?

2006-11-05 Thread Gary Poster


On Nov 5, 2006, at 1:12 PM, Peter Bengtsson wrote:

In Zope2 every object has an 'id' which meant that you can use  
someobject.getId() to find out what name the object is stored under  
in its container.

Is there an equivalent in zope3?


__name__
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


[Zope3-Users] Re: A system error occurred message

2006-11-05 Thread Philipp von Weitershausen

Hi Shailesh,

I'm CC'ing the list again so that it gets archived. Please always 
respond to the list as well.


Shailesh Kumar wrote:

Thank you Philipp it works.

Just a small question.
In a URL like:
http://localhost:8080/++debug++errors/@@undoPrincipalTransactions.html

how does the ++debug++errors work?


It adds the debug skin elements to your current skin.


I don't understand the role of ++ and @@ in URLs well till now.


++name++something means that the traversal adapter called name will be 
called to traverse something. For example, foo/index.html could be an 
object called index.html in the foo folder, but it could also be the 
index.html view for the foo folder. So disambiguate, we say 
foo/++view++index.html to explicitly traverse a view. @@ is a shortcut 
for that: foo/@@index.html.


On 11/4/06, *Philipp von Weitershausen* [EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED] wrote:




Shailesh Kumar wrote:
  Hi all,
  I am a new zope3 user. I am running zope3 in developer mode with
runzope
  command. A number of times (off course when I am doing something
wrong)
  it happens that zope3 gives a blank page with just one line
information:
  'A system error occurred'
 
  Is there some mechanism to be able to see more details about this
system
  error in the browser itself?

Use the Debug skin via ++skin++Debug or via ++debug++errors (the latter
is better if you still want to see your own skin).




___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] getId in zope3?

2006-11-05 Thread Stephan Richter
On Sunday 05 November 2006 13:58, Gary Poster wrote:
 On Nov 5, 2006, at 1:12 PM, Peter Bengtsson wrote:
  In Zope2 every object has an 'id' which meant that you can use  
  someobject.getId() to find out what name the object is stored under  
  in its container.
  Is there an equivalent in zope3?

 __name__

This is officially an implementation detail; zope.traversing.api.getName() is 
the API call.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics  Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] getId in zope3?

2006-11-05 Thread Fred Drake

On 11/5/06, Stephan Richter [EMAIL PROTECTED] wrote:

This is officially an implementation detail; zope.traversing.api.getName() is
the API call.


Interesting; I'd never known it was anything other than __name__.
These APIs just keep changing...

(Er, this indicates a serious documentation problem, I think.
Documentation embedded all over the source tree is far better than
nothing, and good for maintainers, but still totally stinks for end
users.  And, well, for maintainers too, if you need to understand the
public interface.)


 -Fred

--
Fred L. Drake, Jr.fdrake at gmail.com
Every sin is the result of a collaboration. --Lucius Annaeus Seneca
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] getId in zope3?

2006-11-05 Thread Jim Fulton

Fred Drake wrote:

On 11/5/06, Stephan Richter [EMAIL PROTECTED] wrote:
This is officially an implementation detail; 
zope.traversing.api.getName() is

the API call.


Interesting; I'd never known it was anything other than __name__.
These APIs just keep changing...


No, the APIs haven't changed.  It's really a question of best practice
and that evolves over time.  We created a formal API, getName,
because we were queasy about exposing __name__.  In practice, there
is no other implementation and using __name__ is cleaner in a lot of
ways, IMO.

Jim

--
Jim Fulton   mailto:[EMAIL PROTECTED]   Python Powered!
CTO  (540) 361-1714http://www.python.org
Zope Corporation http://www.zope.com   http://www.zope.org
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


[Zope3-Users] Workflow

2006-11-05 Thread Karel Antonio Verdecia Ortiz
Hi:

Is there a workflow engine for zope3
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users