Issue 107263 - Wrong constructor used for new-style services in Basic
Summary: Wrong constructor used for new-style services in Basic
Status: CLOSED FIXED
Alias: None
Product: General
Classification: Code
Component: scripting (show other issues)
Version: OOO320m5
Hardware: All All
: P3 Trivial (vote)
Target Milestone: OOo 3.2
Assignee: thorsten.martens
QA Contact: issues@framework
URL:
Keywords:
Depends on:
Blocks: 99999
  Show dependency tree
 
Reported: 2009-11-27 10:38 UTC by niklas.nebel
Modified: 2017-05-20 10:29 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description niklas.nebel 2009-11-27 10:38:58 UTC
When calling a new-style service constructor in Basic, the name of the
constructor is ignored and the last defined constructor is used
(SbUnoService::Find). The following example gives an error because createKnown
is called instead of create.

Sub Main
    UriService = com.sun.star.rdf.URI
    oSubject = UriService.create("http://hallo/hallo")
    print oSubject.StringValue
End Sub
Comment 1 ab 2009-11-27 11:08:58 UTC
STARTED
Comment 2 uwe.luebbers 2009-11-27 16:53:47 UTC
adjusted target
Comment 3 ab 2009-11-30 13:14:46 UTC
Fixed in basic/source/classes/sbunoobj.cxx

Extended test macro using all three ctors:

Sub Main
    UriService = com.sun.star.rdf.URI
    
    oSubject = UriService.create("http://hallo/hallo")
    print oSubject.StringValue
    
    oSubjectNS = UriService.createNS("ftp:","//foo/bar")
    print oSubjectNS.StringValue
    
    oSubjectKnown = UriService.createKnown(com.sun.star.rdf.URIs.XSD_DECIMAL)
    print oSubjectKnown.StringValue
End Sub
Comment 4 carsten.driesner 2009-12-04 15:44:35 UTC
cd->ab: Please send issue to QA or verify yourself.
Comment 5 ab 2009-12-07 09:10:54 UTC
ab->tm: Please verify. To to this you just need to open the Basic IDE
(Tools / Macros / Organize Macros / Basic... or simple Alt-F11 + Edit)
and copy the test macro above into a module. It should run (F5) without
errors showing the expected results.
Comment 6 thorsten.martens 2009-12-08 12:37:58 UTC
checked and verified in cws fwk131 -> OK !