Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
S
sap-service
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
曲欣亮
sap-service
Commits
384c3271
Commit
384c3271
authored
Aug 13, 2019
by
Quxl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x
parent
a1d9b6ce
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
24 deletions
+16
-24
SAPServiceFactory.java
src/main/java/com/egolm/sso/clients/SAPServiceFactory.java
+16
-24
No files found.
src/main/java/com/egolm/sso/clients/SAPServiceFactory.java
View file @
384c3271
...
...
@@ -50,14 +50,10 @@ public class SAPServiceFactory {
private
String
getAbsolutePath
(
String
WSDLPATH
)
{
if
(
absolutePath
==
null
)
{
synchronized
(
absolutePath
)
{
if
(
absolutePath
==
null
)
{
ApplicationHome
home
=
new
ApplicationHome
(
getClass
());
File
jarFile
=
home
.
getSource
();
File
folder
=
jarFile
.
getParentFile
();
absolutePath
=
folder
.
getAbsolutePath
();
}
}
ApplicationHome
home
=
new
ApplicationHome
(
getClass
());
File
jarFile
=
home
.
getSource
();
File
folder
=
jarFile
.
getParentFile
();
absolutePath
=
folder
.
getAbsolutePath
();
}
return
"file:///"
+
absolutePath
+
"/"
+
WSDLPATH
;
}
...
...
@@ -66,23 +62,19 @@ public class SAPServiceFactory {
public
WSS4JOutInterceptor
getWSS4JOutInterceptor
()
{
if
(
wss4JOutInterceptor
==
null
)
{
synchronized
(
wss4JOutInterceptor
)
{
if
(
wss4JOutInterceptor
==
null
)
{
Map
<
String
,
Object
>
pro
=
new
HashMap
<
String
,
Object
>();
pro
.
put
(
WSHandlerConstants
.
ACTION
,
WSHandlerConstants
.
USERNAME_TOKEN
);
pro
.
put
(
WSHandlerConstants
.
USER
,
username
);
pro
.
put
(
WSHandlerConstants
.
PASSWORD_TYPE
,
PasswordType
.
PasswordText
.
name
());
pro
.
put
(
WSHandlerConstants
.
PW_CALLBACK_REF
,
new
CallbackHandler
()
{
public
void
handle
(
Callback
[]
callbacks
)
{
for
(
int
i
=
0
;
i
<
callbacks
.
length
;
i
++)
{
WSPasswordCallback
pc
=
(
WSPasswordCallback
)
callbacks
[
i
];
pc
.
setPassword
(
password
);
}
}
});
wss4JOutInterceptor
=
new
WSS4JOutInterceptor
(
pro
);
Map
<
String
,
Object
>
pro
=
new
HashMap
<
String
,
Object
>();
pro
.
put
(
WSHandlerConstants
.
ACTION
,
WSHandlerConstants
.
USERNAME_TOKEN
);
pro
.
put
(
WSHandlerConstants
.
USER
,
username
);
pro
.
put
(
WSHandlerConstants
.
PASSWORD_TYPE
,
PasswordType
.
PasswordText
.
name
());
pro
.
put
(
WSHandlerConstants
.
PW_CALLBACK_REF
,
new
CallbackHandler
()
{
public
void
handle
(
Callback
[]
callbacks
)
{
for
(
int
i
=
0
;
i
<
callbacks
.
length
;
i
++)
{
WSPasswordCallback
pc
=
(
WSPasswordCallback
)
callbacks
[
i
];
pc
.
setPassword
(
password
);
}
}
}
});
wss4JOutInterceptor
=
new
WSS4JOutInterceptor
(
pro
);
}
return
wss4JOutInterceptor
;
}
...
...
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