Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Content Management (Extended ECM)
CSIDE and OScript
.New() vs OS.NewTemp()
Yurie_Nagorny_(ynagorny_-_(deleted))
Can someone help me understand this code (from (LLIApi Root).Startup):lliapi.AuditCallbackSubsystem = lliapi.AuditCallbackSubsystem.New() Construct node callback Subsystem.lliapi.NodeCallbacksSubsystem = OS.NewTemp(lliapi.NodeCallbacksSubsystem )I have 2 questions about it:1. Is calling .New() the same as OS.NewTemp()2. What are the semantics of assignment to a OSpace child object? For example, how lliapi.AuditCallbackSubsystem changes after it is assinged result of .New() on itself?Thank you
Find more posts tagged with
Comments
Hans Stoop
Message from Hans Stoop via eLink1. You can have a look at the .New() function and see that it does morethen only calling OS.NewTemp().2. lliapi.AuditCallbackSubsystem = lliapi.AuditCallbackSubsystem.New() is equivalent to dynamic a = lliapi.AuditCallbackSubsystem.New() lliapi.AuditCallbackSubsystem = aHans> -----Original Message-----> From: eLink Discussion: Livelink Builder Discussion > [mailto:componentbuilder@elinkkc.opentext.com] > Sent: donderdag 18 januari 2007 18:07> To: eLink Recipient> Subject: .New() vs OS.NewTemp()> > New() vs OS.NewTemp()> Posted by Nagorny, Yurie on 01/18/2007 12:05 PM> > Can someone help me understand this code (from (LLIApi Root).Startup):> > lliapi.AuditCallbackSubsystem = lliapi.AuditCallbackSubsystem.New()> > Construct node callback Subsystem.> lliapi.NodeCallbacksSubsystem = > OS.NewTemp(lliapi.NodeCallbacksSubsystem )> > I have 2 questions about it:> 1. Is calling .New() the same as OS.NewTemp() 2. What are the > semantics of assignment to a OSpace child object? For > example, how lliapi.AuditCallbackSubsystem changes after it > is assinged result of .New() on itself?> > Thank you> > [To reply to this thread, use your normal E-mail reply function.]> > ============================================================> > Discussion: Livelink Builder Discussion>
https://knowledge.opentext.com/knowledge/llisapi.dll/open/765419>
; > Livelink Server:>
https://knowledge.opentext.com/knowledge/llisapi.dll>
; > To Unsubscribe from this Discussion, send an e-mail to > unsubscribe.componentbuilder@elinkkc.opentext.com.> > >
sıɹɥɔ
Message from Chris Webster <
cwebster@opentext.com
> via eLink
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">eLink
Hi Yurie,
Good questions!
In answer to your first question
Is calling .New() the same as OS.NewTemp()
No they are different:
.New() is a call to the oscript in the feature named "New"; you can review this oscript in Builder to see what it does.
OS.NewTemp() is a call to the NewTemp method in the OS Package; this method is builtin to Livelink - it creates a temporary child of an object.
As for your second question regarding the code
lliapi.NodeCallbacksSubsystem = OS.NewTemp(lliapi.NodeCallbacksSubsystem )
The code is not actually assigning to an object.
lliapi.AuditCallbackSubsystem
is a feature of the Globals object in the LLIAPI ospace. This feature has type Object, which is actually a
reference
to an object. The effect of the assignment is that this feature now has a reference to a new copy of the object originally referenced.
This is a very common idiom in Livelink; it takes a little while to appreciate it though.
Chris Webster
cwebster@opentext.com
From:
eLink Discussion: Livelink Builder Discussion [mailto:componentbuilder@elinkkc.opentext.com]
Sent:
Thursday, January 18, 2007 11:07 AM
To:
eLink Recipient
Subject:
.New() vs OS.NewTemp()
.New() vs OS.NewTemp()
Posted by
ynagorny
(Nagorny, Yurie) on 01/18/2007 12:05 PM
Can someone help me understand this code (from (LLIApi Root).Startup):
lliapi.AuditCallbackSubsystem = lliapi.AuditCallbackSubsystem.New()
Construct node callback Subsystem.
lliapi.NodeCallbacksSubsystem = OS.NewTemp(lliapi.NodeCallbacksSubsystem )
I have 2 questions about it:
1. Is calling .New() the same as OS.NewTemp()
2. What are the semantics of assignment to a OSpace child object? For example, how lliapi.AuditCallbackSubsystem changes after it is assinged result of .New() on itself?
Thank you
Louis_Routhier
I often got code with frames defined in it. Except for being quite harsh to debug, what is the difference between the two? What is the real concept behind frames?