1 package com.calipso.reportgenerator.common; 2 3 import com.calipso.reportgenerator.common.ReportGeneratorConfiguration; 4 import com.calipso.reportgenerator.common.RemoteReportManager; 5 import com.calipso.reportgenerator.enterprise.common.ReportManagerSLHome; 6 import com.calipso.reportgenerator.enterprise.common.ReportManagerSL; 7 import com.calipso.reportgenerator.reportdefinitions.ReportView; 8 import com.calipso.reportgenerator.reportdefinitions.ReportDefinition; 9 import com.calipso.reportgenerator.reportdefinitions.ReportSourceDefinition; 10 import com.calipso.reportgenerator.reportcalculator.Matrix; 11 import java.rmi.RemoteException ; 12 import java.util.*; 13 import java.text.MessageFormat ; 14 import javax.naming.Context ; 15 import javax.naming.InitialContext ; 16 17 18 26 27 public class RemoteReportManagerStateLess extends RemoteReportManager { 28 29 private ReportManagerSL reportManagerRemote; 30 private String clientIp; 31 32 36 public ReportManagerSL getReportManagerRemote() throws InfoException { 37 if (reportManagerRemote == null) { 38 reportManagerRemote = newReportManagerRemote(); 39 } 40 return reportManagerRemote; 41 } 42 43 49 private ReportManagerSL newReportManagerRemote() throws InfoException { 50 Hashtable env = getEnviroment(); 53 try { 54 Context ctx = new InitialContext (env); 55 Object obj = ctx.lookup(getReportGeneratorConfiguration().getReportManagerEJB_SLName()); 56 ReportManagerSLHome home = (ReportManagerSLHome) javax.rmi.PortableRemoteObject.narrow(obj, ReportManagerSLHome.class); 57 ReportManagerSL reportManager = home.create(); 58 return reportManager; 59 } catch (Exception e) { 60 throw new InfoException(LanguageTraslator.traslate("88"), e); 61 } 62 } 63 64 public RemoteReportManagerStateLess(ReportGeneratorConfiguration reportGeneratorConfiguration, String distributedHost) { 65 super(reportGeneratorConfiguration, distributedHost); 66 } 67 68 public int PrepareReport(String reportDefId, Map paramValues) throws InfoException { 69 try { 70 return getReportManagerRemote().PrepareReport(getReportGeneratorConfiguration(), reportDefId, paramValues); 71 } 72 catch (RemoteException e) { 73 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-PrepareReport(String reportDefId, Map paramValues)"}), e); 74 } 75 } 76 77 public int PrepareReport(String reportDefinitionID) throws InfoException { 78 try { 79 return getReportManagerRemote().PrepareReport(getReportGeneratorConfiguration(), reportDefinitionID); 80 } 81 catch (RemoteException e) { 82 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-PrepareReport(String reportDefinitionID)"}), e); 83 } 84 }; 85 public void ReleaseReport(int handle) throws InfoException { 86 try { 87 getReportManagerRemote().ReleaseReport(getReportGeneratorConfiguration(), handle); 88 } 89 catch (RemoteException e) { 90 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ReleaseReport(int handle)"}), e); 91 } 92 } 93 94 public void prepareReportSource(String reportSourceDefinitionId) throws InfoException { 95 try { 96 getReportManagerRemote().prepareReportSource(getReportGeneratorConfiguration(), reportSourceDefinitionId); 97 } 98 catch (RemoteException e) { 99 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-prepareReportSource(String reportSourceDefinitionId) "}), e); 100 } 101 102 } 103 104 public Map getReportDefinitions() throws InfoException { 105 try { 106 return getReportManagerRemote().getReportDefinitions(getReportGeneratorConfiguration()); 107 } 108 catch (RemoteException e) { 109 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportDefinitions() "}), e); 110 } 111 } 112 113 public Map getReportSourceDefinitions() throws InfoException { 114 try { 115 return getReportManagerRemote().getReportSourceDefinitions(getReportGeneratorConfiguration()); 116 } 117 catch (RemoteException e) { 118 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportSourceDefinitions() "}), e); 119 } 120 } 121 122 public Map getReportsForEntity(String entityID) throws InfoException { 123 try { 124 return getReportManagerRemote().getReportsForEntity(getReportGeneratorConfiguration(), entityID); 125 } 126 catch (RemoteException e) { 127 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportsForEntity(String entityID) "}), e); 128 } 129 } 130 131 public void ExecuteAction(int handle, String actionName, Object params) throws InfoException { 132 try { 133 getReportManagerRemote().ExecuteAction(getReportGeneratorConfiguration(), handle, actionName, params); 134 } 135 catch (RemoteException e) { 136 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecuteAction(int handle, String actionName, Object params) "}), e); 137 } 138 } 139 140 public void saveReportDefinition(ReportDefinition reportDefinition) throws InfoException { 141 try { 142 getReportManagerRemote().saveReportDefinition(getReportGeneratorConfiguration(), reportDefinition); 143 } 144 catch (RemoteException e) { 145 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-saveReportDefinition(ReportDefinition reportDefinition) "}), e); 146 } 147 } 148 149 150 public void saveReportSourceDefinition(ReportSourceDefinition reportSourceDefinition) throws InfoException { 151 try { 152 getReportManagerRemote().saveReportSourceDefinition(getReportGeneratorConfiguration(), reportSourceDefinition); 153 } 154 catch (RemoteException e) { 155 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-saveReportSourceDefinition(ReportSourceDefinition reportSourceDefinition) "}), e); 156 } 157 } 158 159 public void invalidateReportSource(String reportSourceDefinitionId) throws InfoException { 160 try { 161 getReportManagerRemote().invalidateReportSource(getReportGeneratorConfiguration(), reportSourceDefinitionId); 162 } 163 catch (RemoteException e) { 164 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-invalidateReportSource(String reportSourceDefinitionId) "}), e); 165 } 166 } 167 168 public ReportQuery getReportQuery(int handle) throws InfoException { 169 try { 170 return getReportManagerRemote().getReportQuery(getReportGeneratorConfiguration(), handle); 171 } 172 catch (RemoteException e) { 173 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportQuery(int handle) "}), e); 174 } 175 } 176 177 public ReportQuery getDefaultReportQuery(int handle) throws InfoException { 178 try { 179 return getReportManagerRemote().getDefaultReportQuery(getReportGeneratorConfiguration(), handle); 180 } 181 catch (RemoteException e) { 182 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getDefaultReportQuery(int handle) "}), e); 183 } 184 } 185 186 public ReportQuery getReportQuery(String reportDefinitionId) throws InfoException { 187 try { 188 return getReportManagerRemote().getReportQuery(getReportGeneratorConfiguration(), reportDefinitionId); 189 } 190 catch (RemoteException e) { 191 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportQuery(String reportDefinitionId) "}), e); 192 } 193 } 194 195 public ReportQuery getDefaultReportQuery(String reportDefinitionId) throws InfoException { 196 try { 197 return getReportManagerRemote().getDefaultReportQuery(getReportGeneratorConfiguration(), reportDefinitionId); 198 } 199 catch (RemoteException e) { 200 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getDefaultReportQuery(String reportDefinitionId) "}), e); 201 } 202 } 203 204 public ReportResult ExecReportQuery(int handle, Map paramValues) throws InfoException { 205 try { 206 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), handle, paramValues); 207 } 208 catch (RemoteException e) { 209 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecReportQuery(int handle, Map paramValues)"}), e); 210 } 211 } 212 213 public ReportResult ExecReportQuery(int handle, ReportQuery query) throws InfoException { 214 try { 215 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), handle, query); 216 } 217 catch (RemoteException e) { 218 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecReportQuery(int handle, ReportQuery query)"}), e); 219 } 220 } 221 222 public ReportResult ExecReportQuery(String reportDefinitionID, Map paramValues) throws InfoException { 223 try { 224 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), reportDefinitionID, paramValues); 225 } 226 catch (RemoteException e) { 227 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecReportQuery(String reportDefinitionID, Map paramValues) "}), e); 228 } 229 } 230 231 public ReportResult ExecReportQuery(String reportDefinitionID, ReportQuery query) throws InfoException { 232 try { 233 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), reportDefinitionID, query); 234 } 235 catch (RemoteException e) { 236 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecReportQuery(String reportDefinitionID, ReportQuery query)"}), e); 237 } 238 } 239 240 public ReportQuery getDefaultReportQuery(int handle,String userID) throws InfoException{ 241 try { 242 return getReportManagerRemote().getDefaultReportQuery(getReportGeneratorConfiguration(), handle, userID); 243 } 244 catch (RemoteException e) { 245 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getDefaultReportQuery(int handle,String userID)"}), e); 246 } 247 }; 248 249 public Map getReportViews(String reportDefinitionID, String userID) throws InfoException{ 250 try { 251 return getReportManagerRemote().getReportViews(getReportGeneratorConfiguration(), reportDefinitionID, userID); 252 } 253 catch (RemoteException e) { 254 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportViews(String reportDefinitionID, String userID)"}), e); 255 } 256 }; 257 258 public Map getReportViews(String reportDefinitionID) throws InfoException{ 259 try { 260 return getReportManagerRemote().getReportViews(getReportGeneratorConfiguration(), reportDefinitionID); 261 } 262 catch (RemoteException e) { 263 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-getReportViews(String reportDefinitionID)"}), e); 264 } 265 }; 266 267 public ReportResult ExecReportQuery(int handle, String reportViewId) throws InfoException{ 268 try { 269 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), handle, reportViewId); 270 } 271 catch (RemoteException e) { 272 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateless-ExecReportQuery(int handle, String reportViewId)"}), e); 273 } 274 }; 275 276 public ReportSpec getReportSpec(String reportDefinitionId, String reportSourceDefId) throws InfoException { 277 try { 278 return getReportManagerRemote().getReportSpec(getReportGeneratorConfiguration(), reportDefinitionId, reportSourceDefId); 279 } 280 catch (RemoteException e) { 281 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportSpec(String reportDefinitionId, String reportSourceDefId)"}), e); 282 } 283 } 284 285 public ReportSpec getReportSpec(ReportDefinition reportDefinition, ReportSourceDefinition reportSourceDef) throws InfoException { 286 try { 287 return getReportManagerRemote().getReportSpec(getReportGeneratorConfiguration(), reportDefinition, reportSourceDef); 288 } 289 catch (RemoteException e) { 290 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"getReportSpec(ReportDefinition reportDefinition, ReportSourceDefinition reportSourceDef)"}), e); 291 } 292 } 293 294 public ReportSpec getReportSpec(String reportDefinitionId) throws InfoException { 295 try { 296 return getReportManagerRemote().getReportSpec(getReportGeneratorConfiguration(), reportDefinitionId); 297 } 298 catch (RemoteException e) { 299 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportSpec(String reportDefinitionId)"}), e); 300 } 301 } 302 303 public ReportView getReportView(String reportViewId) throws InfoException { 304 try { 305 return getReportManagerRemote().getReportView(getReportGeneratorConfiguration(), reportViewId); 306 } 307 catch (RemoteException e) { 308 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportView(String reportViewId)"}), e); 309 } 310 } 311 312 public void saveReportView(ReportView reportView) throws InfoException { 313 try { 314 getReportManagerRemote().saveReportView(getReportGeneratorConfiguration(), reportView); 315 } 316 catch (RemoteException e) { 317 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-saveReportView(ReportView reportView)"}), e); 318 } 319 } 320 321 public ReportView getReportViewFromID(String id, String reportDefinitionId, String userId) throws InfoException { 322 try { 323 return getReportManagerRemote().getReportViewFromID(getReportGeneratorConfiguration(), id, reportDefinitionId, userId); 324 } 325 catch (RemoteException e) { 326 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportViewFromID(String id, String reportDefinitionId, String userId)"}), e); 327 } 328 } 329 330 public ReportResult ExecReportQuery(int handle, ReportView reportView) throws InfoException { 331 try { 332 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), handle, reportView); 333 } 334 catch (RemoteException e) { 335 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-ExecReportQuery(int handle, ReportView reportView)"}), e); 336 } 337 } 338 339 public void registerDefinitions() throws InfoException { 340 try { 341 getReportManagerRemote().registerDefinitions(getReportGeneratorConfiguration()); 342 } 343 catch (RemoteException e) { 344 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-registerDefinitions()"}), e); 345 } 346 } 347 348 public void deleteAllRepositories() throws InfoException { 349 try { 350 getReportManagerRemote().deleteAllRepositories(getReportGeneratorConfiguration()); 351 } 352 catch (RemoteException e) { 353 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteAllRepositories()"}), e); 354 } 355 } 356 357 public void deleteAllDefinitions() throws InfoException { 358 try { 359 getReportManagerRemote().deleteAllDefinitions(getReportGeneratorConfiguration()); 360 } 361 catch (RemoteException e) { 362 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteAllDefinitions()"}), e); 363 } 364 } 365 366 public void deleteReportSourceRepository() throws InfoException { 367 try { 368 getReportManagerRemote().deleteReportSourceRepository(getReportGeneratorConfiguration()); 369 } 370 catch (RemoteException e) { 371 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportSourceRepository()"}), e); 372 } 373 } 374 375 public void deleteReportSourceDefinitionRepository() throws InfoException { 376 try { 377 getReportManagerRemote().deleteReportSourceDefinitionRepository(getReportGeneratorConfiguration()); 378 } 379 catch (RemoteException e) { 380 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportSourceDefinitionRepository()"}), e); 381 } 382 } 383 384 public void deleteReportDefinitionRepository() throws InfoException { 385 try { 386 getReportManagerRemote().deleteReportDefinitionRepository(getReportGeneratorConfiguration()); 387 } 388 catch (RemoteException e) { 389 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportDefinitionRepository()"}), e); 390 } 391 } 392 393 public void deleteReportViewRepository() throws InfoException { 394 try { 395 getReportManagerRemote().deleteReportViewRepository(getReportGeneratorConfiguration()); 396 } 397 catch (RemoteException e) { 398 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportViewRepository()"}), e); 399 } 400 } 401 402 public void deleteReportView(String id, String reportDefinitionId, String userId) throws InfoException { 403 try { 404 getReportManagerRemote().deleteReportView(getReportGeneratorConfiguration(), id,reportDefinitionId,userId); 405 } 406 catch (RemoteException e) { 407 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportView(String id, String reportDefinitionId, String userId)"}), e); 408 } 409 } 410 411 public void deleteReportSource(String reportSourceDefinitionId) throws InfoException { 412 try { 413 getReportManagerRemote().deleteReportSource(getReportGeneratorConfiguration(), reportSourceDefinitionId); 414 } 415 catch (RemoteException e) { 416 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportSource(String reportSourceDefinitionId)"}), e); 417 } 418 } 419 420 public void deleteReportSourceDefinition(String reportSourceDefinitionID) throws InfoException { 421 try { 422 getReportManagerRemote().deleteReportSourceDefinition(getReportGeneratorConfiguration(), reportSourceDefinitionID); 423 } 424 catch (RemoteException e) { 425 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportSourceDefinition(String reportSourceDefinitionID)"}), e); 426 } 427 } 428 429 public void deleteReportDefinition(String reportDefinitionID) throws InfoException { 430 try { 431 getReportManagerRemote().deleteReportDefinition(getReportGeneratorConfiguration(), reportDefinitionID); 432 } 433 catch (RemoteException e) { 434 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-deleteReportDefinition(String reportDefinitionID)"}), e); 435 } 436 } 437 438 public void assingDefaultView(String id, String reportDefinitionId, String userId) throws InfoException { 439 try { 440 getReportManagerRemote().assingDefaultView(getReportGeneratorConfiguration(), id, reportDefinitionId, userId); 441 } 442 catch (RemoteException e) { 443 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-assingDefaultView(String id, String reportDefinitionId, String userId)"}), e); 444 } 445 } 446 447 public ReportResult ExecReportQuery(MicroReport microReport) throws InfoException { 448 try { 449 return getReportManagerRemote().ExecReportQuery(getReportGeneratorConfiguration(), microReport); 450 } 451 catch (RemoteException e) { 452 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-ExecReportQuery(MicroReport microReport)"}), e); 453 } 454 } 455 456 public int PrepareReport(MicroReport microReport) throws InfoException { 457 try { 458 return getReportManagerRemote().PrepareReport(getReportGeneratorConfiguration(), microReport); 459 } 460 catch (RemoteException e) { 461 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-PrepareReport(MicroReport microReport)"}), e); 462 } 463 } 464 465 public String getXML(int handle) throws InfoException { 466 try { 467 return getReportManagerRemote().getXML(getReportGeneratorConfiguration(), handle); 468 } 469 catch (RemoteException e) { 470 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getXML(int handle)"}), e); 471 } 472 473 } 474 475 public String getXML(String reportDefinitionID, Map paramValues) throws InfoException { 476 try { 477 return getReportManagerRemote().getXML(getReportGeneratorConfiguration(), reportDefinitionID,paramValues); 478 } 479 catch (RemoteException e) { 480 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getXML(String reportDefinitionID, Map paramValues)"}), e); 481 } 482 } 483 484 public Set getDimensionValues(int handle, String name) throws InfoException { 485 try { 486 return getReportManagerRemote().getDimensionValues(getReportGeneratorConfiguration(), handle,name); 487 } 488 catch (RemoteException e) { 489 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getDimensionValues(int handle, String name)"}), e); 490 } 491 492 } 493 494 public Set getDimensionValues(String reportDefinitionID, Map paramValues, String name) throws InfoException { 495 try { 496 return getReportManagerRemote().getDimensionValues(getReportGeneratorConfiguration(), reportDefinitionID,paramValues,name); 497 } 498 catch (RemoteException e) { 499 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getDimensionValues(String reportDefinitionID, Map paramValues, String name)"}), e); 500 } 501 } 502 503 public Vector getUpdatedDataModel(int handle, int mode, int row, int col, boolean isDistributed) throws InfoException { 504 try { 505 return getReportManagerRemote().getUpdatedDataModel(getReportGeneratorConfiguration(), handle, mode, row, col, isDistributed); 506 } 507 catch (RemoteException e) { 508 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getUpdatedDataModel(int handle, int mode, int row, int col, boolean isDistributed) "}), e); 509 } 510 } 511 512 public Matrix getMatrix(int handle) throws InfoException { 513 try { 514 return getReportManagerRemote().getMatrix(getReportGeneratorConfiguration(), handle); 515 } 516 catch (RemoteException e) { 517 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getMatrix(int handle) "}), e); 518 } 519 } 520 521 public ReportDefinition getReportDefinitionFromID(String reportDefinitionId) throws InfoException { 522 try { 523 return getReportManagerRemote().getReportDefinitionFromID(getReportGeneratorConfiguration(), reportDefinitionId); 524 } 525 catch (RemoteException e) { 526 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportDefinitionFromID(String reportDefinitionId) "}), e); 527 } 528 } 529 530 public ReportSourceDefinition getReportSourceDefinitionFromID(String reportSourceDefinitionId) throws InfoException { 531 try { 532 return getReportManagerRemote().getReportSourceDefinitionFromID(getReportGeneratorConfiguration(), reportSourceDefinitionId); 533 } 534 catch (RemoteException e) { 535 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getReportSourceDefinitionFromID(String reportSourceDefinitionId) "}), e); 536 } 537 } 538 539 public void init(ReportGeneratorConfiguration reportGeneratorConfiguration) throws InfoException { 540 } 541 542 public boolean validateUser(String userName, String password, String userRepositoryPath) throws InfoException { 543 try { 544 return getReportManagerRemote().validateUser(getReportGeneratorConfiguration(), userName, password, userRepositoryPath); 545 } 546 catch (RemoteException e) { 547 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-validateUser()) "}), e); 548 } 549 } 550 551 public boolean validateRol(String [] roles, String userName, String rolRepositoryPath) throws InfoException { 552 try { 553 return getReportManagerRemote().validateRol(getReportGeneratorConfiguration(), roles, userName, rolRepositoryPath); 554 } 555 catch (RemoteException e) { 556 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-validateRol()) "}), e); 557 } 558 } 559 560 public void exportReport(String userName, String password, String userRepositoryPath, String reportDefinitionId, Map paramValues, boolean isLandscape, int type, String destinationPath, String name) throws InfoException { 561 try { 562 getReportManagerRemote().exportReport(getReportGeneratorConfiguration(), userName, password, userRepositoryPath, reportDefinitionId, paramValues, isLandscape, type, destinationPath, name); 563 } 564 catch (RemoteException e) { 565 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-exportReport()) "}), e); 566 } 567 568 } 569 570 public byte[] exportReport(Map params) throws InfoException { 571 try { 572 return getReportManagerRemote().exportReport(getReportGeneratorConfiguration(), params); 573 } 574 catch (RemoteException e) { 575 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-exportReport()) "}), e); 576 } 577 } 578 579 public boolean addNewUser(String rootPasswd, String userName, String password, String userRepositoryPath) throws InfoException { 580 try { 581 return getReportManagerRemote().addNewUser(getReportGeneratorConfiguration(), rootPasswd, userName, password, userRepositoryPath); 582 } catch (RemoteException e) { 583 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-addNewUser()) "}), e); 584 } 585 } 586 587 public void addUserData(String userName, String name, String company, String userDataRepositoryPath) throws InfoException { 588 try { 589 getReportManagerRemote().addUserData(getReportGeneratorConfiguration(), userName, name, company, userDataRepositoryPath); 590 } catch (RemoteException e) { 591 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-addUserData()) "}), e); 592 } 593 } 594 595 public void addUserRol(String userName, String rol, String rolsRepositoryPath) throws InfoException { 596 try { 597 getReportManagerRemote().addUserRol(getReportGeneratorConfiguration(), userName, rol, rolsRepositoryPath); 598 } catch (RemoteException e) { 599 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-addUserRol()) "}), e); 600 } 601 } 602 603 public boolean isAcceptedLicence() throws InfoException { 604 try { 605 return getReportManagerRemote().isAcceptedLicence(getReportGeneratorConfiguration()); 606 } catch (RemoteException e) { 607 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-isAcceptedLicence())) "}), e); 608 } 609 } 610 611 public void acceptedLicence(boolean value) throws InfoException { 612 try { 613 getReportManagerRemote().acceptedLicence(getReportGeneratorConfiguration(), value); 614 } catch (RemoteException e) { 615 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-acceptedLicence())) "}), e); 616 } 617 } 618 619 public MicroReport getMicroReport(String fileName) throws InfoException { 620 try { 621 return getReportManagerRemote().getMicroReport(getReportGeneratorConfiguration(), fileName); 622 } catch (RemoteException e) { 623 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getMicroReport()) "}), e); 624 } 625 } 626 627 public MicroReport getMicroReport(String reportDefinitionId, Map param) throws InfoException { 628 try { 629 return getReportManagerRemote().getMicroReport(getReportGeneratorConfiguration(), reportDefinitionId,param); 630 } catch (RemoteException e) { 631 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getMicroReport()) "}), e); 632 } 633 } 634 635 public Collection getUserData(String userId, String userDataRepositoryPath) throws InfoException { 636 try { 637 return getReportManagerRemote().getUserData(getReportGeneratorConfiguration(), userId, userDataRepositoryPath); 638 } catch (RemoteException e) { 639 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getUserData()) "}), e); 640 } 641 } 642 643 public void logClientData(String clientData) throws InfoException { 644 try { 645 getReportManagerRemote().logClientData(getReportGeneratorConfiguration(), clientData); 646 } catch (RemoteException e) { 647 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-logClientData()) "}), e); 648 } 649 } 650 651 660 public Vector registerReportSourceDefinitions(Vector vector) throws InfoException { 661 try { 662 return getReportManagerRemote().registerReportSourceDefinitions(getReportGeneratorConfiguration(), vector); 663 } 664 catch (RemoteException e) { 665 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-registerReportSourceDefinitions()"}), e); 666 } 667 } 668 669 public Vector registerReportDefinitions(Vector vector) throws InfoException { 670 try { 671 return getReportManagerRemote().registerReportDefinitions(getReportGeneratorConfiguration(), vector); 672 } 673 catch (RemoteException e) { 674 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-registerReportDefinitions()"}), e); 675 } 676 } 677 678 679 public Vector registerReportViews(Vector vector) throws InfoException { 680 try { 681 return getReportManagerRemote().registerReportViews(getReportGeneratorConfiguration(), vector); 682 } 683 catch (RemoteException e) { 684 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-registerReportViews()"}), e); 685 } 686 } 687 688 public String getDefaultReportViewId(String reportDefinitionId, String userId) throws InfoException { 689 try { 690 return getReportManagerRemote().getDefaultReportViewId(getReportGeneratorConfiguration(), reportDefinitionId,userId); 691 } 692 catch (RemoteException e) { 693 throw new InfoException(MessageFormat.format((LanguageTraslator.traslate("87")), new Object []{"RemoteReportManagerStateLess-getDefaultReportViewId(String reportDefinitionId, String userId)"}), e); 694 } 695 } 696 697 } 698 | Popular Tags |