Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
40ecb869
Kaydet (Commit)
40ecb869
authored
Ock 31, 2003
tarafından
Stephan Wunderlich
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
CHG: using AnyConverter instead of simple cast
üst
3b9388e7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
38 additions
and
8 deletions
+38
-8
utils.java
qadevOOo/runner/util/utils.java
+24
-4
ORowSet.java
qadevOOo/tests/java/mod/_dbaccess/ORowSet.java
+14
-4
No files found.
qadevOOo/runner/util/utils.java
Dosyayı görüntüle @
40ecb869
...
@@ -2,9 +2,9 @@
...
@@ -2,9 +2,9 @@
*
*
* $RCSfile: utils.java,v $
* $RCSfile: utils.java,v $
*
*
* $Revision: 1.
1
$
* $Revision: 1.
2
$
*
*
* last change:$Date: 2003-01-
27 16:26:55
$
* last change:$Date: 2003-01-
31 10:35:58
$
*
*
* The Contents of this file are made available subject to the terms of
* The Contents of this file are made available subject to the terms of
* either of the following licenses
* either of the following licenses
...
@@ -80,6 +80,10 @@ import com.sun.star.lang.XServiceInfo;
...
@@ -80,6 +80,10 @@ import com.sun.star.lang.XServiceInfo;
import
com.sun.star.util.URL
;
import
com.sun.star.util.URL
;
import
com.sun.star.util.XURLTransformer
;
import
com.sun.star.util.XURLTransformer
;
import
com.sun.star.uno.Any
;
import
com.sun.star.uno.AnyConverter
;
import
com.sun.star.uno.Type
;
//For database connection
//For database connection
import
java.sql.*
;
import
java.sql.*
;
...
@@ -239,7 +243,16 @@ public class utils {
...
@@ -239,7 +243,16 @@ public class utils {
}
}
XNameAccess
settingNames
=
(
XNameAccess
)
XNameAccess
settingNames
=
(
XNameAccess
)
UnoRuntime
.
queryInterface
(
XNameAccess
.
class
,
settings
);
UnoRuntime
.
queryInterface
(
XNameAccess
.
class
,
settings
);
XPropertySet
pthSettings
=
(
XPropertySet
)
settingNames
.
getByName
(
"PathSettings"
);
Object
pSettings
=
settingNames
.
getByName
(
"PathSettings"
);
XPropertySet
pthSettings
=
null
;
try
{
pthSettings
=
(
XPropertySet
)
AnyConverter
.
toObject
(
new
Type
(
XPropertySet
.
class
),
pSettings
);
}
catch
(
com
.
sun
.
star
.
lang
.
IllegalArgumentException
iae
)
{
System
.
out
.
println
(
"### couldn't convert Any"
);
}
String
tmp
=
(
String
)
pthSettings
.
getPropertyValue
(
"UserPath"
);
String
tmp
=
(
String
)
pthSettings
.
getPropertyValue
(
"UserPath"
);
tmpDir
=
getFullURL
(
tmp
+
"/temp/"
);
tmpDir
=
getFullURL
(
tmp
+
"/temp/"
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
@@ -535,7 +548,14 @@ public class utils {
...
@@ -535,7 +548,14 @@ public class utils {
Object
settings
=
msf
.
createInstance
(
"com.sun.star.frame.Settings"
);
Object
settings
=
msf
.
createInstance
(
"com.sun.star.frame.Settings"
);
XNameAccess
settingNames
=
(
XNameAccess
)
XNameAccess
settingNames
=
(
XNameAccess
)
UnoRuntime
.
queryInterface
(
XNameAccess
.
class
,
settings
);
UnoRuntime
.
queryInterface
(
XNameAccess
.
class
,
settings
);
XPropertySet
pthSettings
=
(
XPropertySet
)
settingNames
.
getByName
(
"PathSettings"
);
Object
pSettings
=
settingNames
.
getByName
(
"PathSettings"
);
XPropertySet
pthSettings
=
null
;
try
{
pthSettings
=
(
XPropertySet
)
AnyConverter
.
toObject
(
new
Type
(
XPropertySet
.
class
),
pSettings
);
}
catch
(
com
.
sun
.
star
.
lang
.
IllegalArgumentException
iae
)
{
System
.
out
.
println
(
"### couldn't convert Any"
);
}
String
path
=
(
String
)
pthSettings
.
getPropertyValue
(
"ProgPath"
);
String
path
=
(
String
)
pthSettings
.
getPropertyValue
(
"ProgPath"
);
return
path
;
return
path
;
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
...
qadevOOo/tests/java/mod/_dbaccess/ORowSet.java
Dosyayı görüntüle @
40ecb869
...
@@ -2,9 +2,9 @@
...
@@ -2,9 +2,9 @@
*
*
* $RCSfile: ORowSet.java,v $
* $RCSfile: ORowSet.java,v $
*
*
* $Revision: 1.
1
$
* $Revision: 1.
2
$
*
*
* last change:$Date: 2003-01-
27 18:14:36
$
* last change:$Date: 2003-01-
31 10:37:25
$
*
*
* The Contents of this file are made available subject to the terms of
* The Contents of this file are made available subject to the terms of
* either of the following licenses
* either of the following licenses
...
@@ -78,6 +78,9 @@ import com.sun.star.sdbc.XRowUpdate;
...
@@ -78,6 +78,9 @@ import com.sun.star.sdbc.XRowUpdate;
import
com.sun.star.sdbcx.XRowLocate
;
import
com.sun.star.sdbcx.XRowLocate
;
import
com.sun.star.uno.UnoRuntime
;
import
com.sun.star.uno.UnoRuntime
;
import
com.sun.star.uno.XInterface
;
import
com.sun.star.uno.XInterface
;
import
com.sun.star.uno.Any
;
import
com.sun.star.uno.AnyConverter
;
import
com.sun.star.uno.Type
;
import
java.io.File
;
import
java.io.File
;
import
java.io.PrintWriter
;
import
java.io.PrintWriter
;
import
java.util.Vector
;
import
java.util.Vector
;
...
@@ -368,8 +371,15 @@ public class ORowSet extends TestCase {
...
@@ -368,8 +371,15 @@ public class ORowSet extends TestCase {
xORowSet
.
execute
()
;
xORowSet
.
execute
()
;
connection
=
(
XConnection
)
connection
=
null
;
xSetProp
.
getPropertyValue
(
"ActiveConnection"
)
;
try
{
connection
=
(
XConnection
)
AnyConverter
.
toObject
(
new
Type
(
XConnection
.
class
),
xSetProp
.
getPropertyValue
(
"ActiveConnection"
));
}
catch
(
com
.
sun
.
star
.
lang
.
IllegalArgumentException
iae
)
{
throw
new
StatusException
(
"couldn't convert Any"
,
iae
);
}
oInterface
=
oRowSet
;
oInterface
=
oRowSet
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment