1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.4.2_12) on Fri Oct 06 15:52:53 GMT 2006 -->
<TITLE>
BSFManager (Bean Scripting Framework API)
</TITLE>
<META NAME="keywords" CONTENT="org.apache.bsf.BSFManager class">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
parent.document.title="BSFManager (Bean Scripting Framework API)";
}
</SCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/BSFManager.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf"><B>PREV CLASS</B></A>
<A HREF="../../../org/apache/bsf/Main.html" title="class in org.apache.bsf"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html" target="_top"><B>FRAMES</B></A>
<A HREF="BSFManager.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.bsf</FONT>
<BR>
Class BSFManager</H2>
<PRE>
java.lang.Object
<IMG SRC="../../../resources/inherit.gif" ALT="extended by"><B>org.apache.bsf.BSFManager</B>
</PRE>
<HR>
<DL>
<DT>public class <B>BSFManager</B><DT>extends java.lang.Object</DL>
<P>
This class is the entry point to the bean scripting framework. An
application wishing to integrate scripting to a Java app would
place an instance of a BSFManager in their code and use its services
to register the beans they want to make available for scripting,
load scripting engines, and run scripts.
<p>
BSFManager serves as the registry of available scripting engines
as well. Loading and unloading of scripting engines is
supported as well. Each BSFManager loads one engine per language.
Several BSFManagers can be created per JVM.
<P>
<P>
<DL>
<DT><B>Author:</B></DT>
<DD>Sanjiva Weerawarana, Matthew J. Duftler, Sam Ruby, Olivier Gruber (added original debugging support), Don Schwarz (added support for registering languages dynamically)</DD>
</DL>
<HR>
<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Field Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.lang.ClassLoader</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#classLoader">classLoader</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#classPath">classPath</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.Vector</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#declaredBeans">declaredBeans</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected static java.util.Hashtable</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#extn2Lang">extn2Lang</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.Hashtable</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#loadedEngines">loadedEngines</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected <A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#objectRegistry">objectRegistry</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.beans.PropertyChangeSupport</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#pcs">pcs</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected static java.util.Hashtable</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#registeredEngines">registeredEngines</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#tempDir">tempDir</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected static java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#version">version</A></B></CODE>
<BR>
</TD>
</TR>
</TABLE>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#BSFManager()">BSFManager</A></B>()</CODE>
<BR>
</TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.Object</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#apply(java.lang.String, java.lang.String, int, int, java.lang.Object, java.util.Vector, java.util.Vector)">apply</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object funcBody,
java.util.Vector paramNames,
java.util.Vector arguments)</CODE>
<BR>
Apply the given anonymous function of the given language to the given
parameters and return the resulting value.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#compileApply(java.lang.String, java.lang.String, int, int, java.lang.Object, java.util.Vector, java.util.Vector, org.apache.bsf.util.CodeBuffer)">compileApply</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object funcBody,
java.util.Vector paramNames,
java.util.Vector arguments,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)</CODE>
<BR>
Compile the application of the given anonymous function of the given
language to the given parameters into the given <tt>CodeBuffer</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#compileExpr(java.lang.String, java.lang.String, int, int, java.lang.Object, org.apache.bsf.util.CodeBuffer)">compileExpr</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object expr,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)</CODE>
<BR>
Compile the given expression of the given language into the given
<tt>CodeBuffer</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#compileScript(java.lang.String, java.lang.String, int, int, java.lang.Object, org.apache.bsf.util.CodeBuffer)">compileScript</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)</CODE>
<BR>
Compile the given script of the given language into the given
<tt>CodeBuffer</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#declareBean(java.lang.String, java.lang.Object, java.lang.Class)">declareBean</A></B>(java.lang.String beanName,
java.lang.Object bean,
java.lang.Class type)</CODE>
<BR>
Declare a bean.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.Object</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#eval(java.lang.String, java.lang.String, int, int, java.lang.Object)">eval</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object expr)</CODE>
<BR>
Evaluate the given expression of the given language and return the
resulting value.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#exec(java.lang.String, java.lang.String, int, int, java.lang.Object)">exec</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)</CODE>
<BR>
Execute the given script of the given language.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.ClassLoader</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getClassLoader()">getClassLoader</A></B>()</CODE>
<BR>
Get classLoader</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getClassPath()">getClassPath</A></B>()</CODE>
<BR>
Get classPath</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getLangFromFilename(java.lang.String)">getLangFromFilename</A></B>(java.lang.String fileName)</CODE>
<BR>
Determine the language of a script file by looking at the file
extension.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getObjectRegistry()">getObjectRegistry</A></B>()</CODE>
<BR>
Return the current object registry of the manager.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getTempDir()">getTempDir</A></B>()</CODE>
<BR>
Get tempDir</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#getVersion()">getVersion</A></B>()</CODE>
<BR>
Returns the version string of BSF.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#iexec(java.lang.String, java.lang.String, int, int, java.lang.Object)">iexec</A></B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)</CODE>
<BR>
Execute the given script of the given language, attempting to
emulate an interactive session w/ the language.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#isLanguageRegistered(java.lang.String)">isLanguageRegistered</A></B>(java.lang.String lang)</CODE>
<BR>
Determine whether a language is registered.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/bsf/BSFEngine.html" title="interface in org.apache.bsf">BSFEngine</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#loadScriptingEngine(java.lang.String)">loadScriptingEngine</A></B>(java.lang.String lang)</CODE>
<BR>
Load a scripting engine based on the lang string identifying it.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.Object</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#lookupBean(java.lang.String)">lookupBean</A></B>(java.lang.String beanName)</CODE>
<BR>
return a handle to a bean registered in the bean registry by the
application or a scripting engine.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#registerBean(java.lang.String, java.lang.Object)">registerBean</A></B>(java.lang.String beanName,
java.lang.Object bean)</CODE>
<BR>
Registering a bean allows a scripting engine or the application to
access that bean by name and to manipulate it.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#registerScriptingEngine(java.lang.String, java.lang.String, java.lang.String[])">registerScriptingEngine</A></B>(java.lang.String lang,
java.lang.String engineClassName,
java.lang.String[] extensions)</CODE>
<BR>
Register a scripting engine in the static registry of the
BSFManager.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#setClassLoader(java.lang.ClassLoader)">setClassLoader</A></B>(java.lang.ClassLoader classLoader)</CODE>
<BR>
Set the class loader for those that need to use it.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#setClassPath(java.lang.String)">setClassPath</A></B>(java.lang.String classPath)</CODE>
<BR>
Set the classpath for those that need to use it.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#setObjectRegistry(org.apache.bsf.util.ObjectRegistry)">setObjectRegistry</A></B>(<A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A> objectRegistry)</CODE>
<BR>
Set the object registry used by this manager.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#setTempDir(java.lang.String)">setTempDir</A></B>(java.lang.String tempDir)</CODE>
<BR>
Temporary directory to put stuff into (for those who need to).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#terminate()">terminate</A></B>()</CODE>
<BR>
Gracefully terminate all engines</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#undeclareBean(java.lang.String)">undeclareBean</A></B>(java.lang.String beanName)</CODE>
<BR>
Undeclare a previously declared bean.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/bsf/BSFManager.html#unregisterBean(java.lang.String)">unregisterBean</A></B>(java.lang.String beanName)</CODE>
<BR>
Unregister a previously registered bean.</TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="version"><!-- --></A><H3>
version</H3>
<PRE>
protected static java.lang.String <B>version</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="registeredEngines"><!-- --></A><H3>
registeredEngines</H3>
<PRE>
protected static java.util.Hashtable <B>registeredEngines</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="extn2Lang"><!-- --></A><H3>
extn2Lang</H3>
<PRE>
protected static java.util.Hashtable <B>extn2Lang</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="loadedEngines"><!-- --></A><H3>
loadedEngines</H3>
<PRE>
protected java.util.Hashtable <B>loadedEngines</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="objectRegistry"><!-- --></A><H3>
objectRegistry</H3>
<PRE>
protected <A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A> <B>objectRegistry</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="pcs"><!-- --></A><H3>
pcs</H3>
<PRE>
protected java.beans.PropertyChangeSupport <B>pcs</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="classLoader"><!-- --></A><H3>
classLoader</H3>
<PRE>
protected java.lang.ClassLoader <B>classLoader</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="tempDir"><!-- --></A><H3>
tempDir</H3>
<PRE>
protected java.lang.String <B>tempDir</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="classPath"><!-- --></A><H3>
classPath</H3>
<PRE>
protected java.lang.String <B>classPath</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="declaredBeans"><!-- --></A><H3>
declaredBeans</H3>
<PRE>
protected java.util.Vector <B>declaredBeans</B></PRE>
<DL>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="BSFManager()"><!-- --></A><H3>
BSFManager</H3>
<PRE>
public <B>BSFManager</B>()</PRE>
<DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="getVersion()"><!-- --></A><H3>
getVersion</H3>
<PRE>
public static java.lang.String <B>getVersion</B>()</PRE>
<DL>
<DD>Returns the version string of BSF.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>version string in the form "abc.yyyymmdd" where
"abc" represents a dewey decimal number (three levels, each between 0 and 9), and
"yyyy" a four digit year, "mm" a two digit month,
"dd" a two digit day.
<br>Example: "<code>240.20061006</code>"
stands for: BSF version <code>2.4.0</code> as of <code>2006-10-06</code>.<DT><B>Since:</B></DT>
<DD>2006-01-17</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="apply(java.lang.String, java.lang.String, int, int, java.lang.Object, java.util.Vector, java.util.Vector)"><!-- --></A><H3>
apply</H3>
<PRE>
public java.lang.Object <B>apply</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object funcBody,
java.util.Vector paramNames,
java.util.Vector arguments)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Apply the given anonymous function of the given language to the given
parameters and return the resulting value.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>funcBody</CODE> - the multi-line, value returning script to evaluate<DD><CODE>paramNames</CODE> - the names of the parameters above assumes<DD><CODE>arguments</CODE> - values of the above parameters
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if anything goes wrong while running the script</DL>
</DD>
</DL>
<HR>
<A NAME="compileApply(java.lang.String, java.lang.String, int, int, java.lang.Object, java.util.Vector, java.util.Vector, org.apache.bsf.util.CodeBuffer)"><!-- --></A><H3>
compileApply</H3>
<PRE>
public void <B>compileApply</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object funcBody,
java.util.Vector paramNames,
java.util.Vector arguments,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Compile the application of the given anonymous function of the given
language to the given parameters into the given <tt>CodeBuffer</tt>.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>funcBody</CODE> - the multi-line, value returning script to evaluate<DD><CODE>paramNames</CODE> - the names of the parameters above assumes<DD><CODE>arguments</CODE> - values of the above parameters<DD><CODE>cb</CODE> - code buffer to compile into
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if anything goes wrong while running the script</DL>
</DD>
</DL>
<HR>
<A NAME="compileExpr(java.lang.String, java.lang.String, int, int, java.lang.Object, org.apache.bsf.util.CodeBuffer)"><!-- --></A><H3>
compileExpr</H3>
<PRE>
public void <B>compileExpr</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object expr,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Compile the given expression of the given language into the given
<tt>CodeBuffer</tt>.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>expr</CODE> - the expression to compile<DD><CODE>cb</CODE> - code buffer to compile into
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if any error while compiling the expression</DL>
</DD>
</DL>
<HR>
<A NAME="compileScript(java.lang.String, java.lang.String, int, int, java.lang.Object, org.apache.bsf.util.CodeBuffer)"><!-- --></A><H3>
compileScript</H3>
<PRE>
public void <B>compileScript</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script,
<A HREF="../../../org/apache/bsf/util/CodeBuffer.html" title="class in org.apache.bsf.util">CodeBuffer</A> cb)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Compile the given script of the given language into the given
<tt>CodeBuffer</tt>.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this script
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for script<DD><CODE>columnNo</CODE> - (context info) the column number in source for script<DD><CODE>script</CODE> - the script to compile<DD><CODE>cb</CODE> - code buffer to compile into
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if any error while compiling the script</DL>
</DD>
</DL>
<HR>
<A NAME="declareBean(java.lang.String, java.lang.Object, java.lang.Class)"><!-- --></A><H3>
declareBean</H3>
<PRE>
public void <B>declareBean</B>(java.lang.String beanName,
java.lang.Object bean,
java.lang.Class type)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Declare a bean. The difference between declaring and registering
is that engines are spsed to make declared beans "pre-available"
in the scripts as far as possible. That is, if a script author
needs a registered bean, he needs to look it up in some way. However
if he needs a declared bean, the language has the responsibility to
make those beans avaialable "automatically."
<p>
When a bean is declared it is automatically registered as well
so that any declared bean can be gotton to by looking it up as well.
<p>
If any of the languages that are already running in this manager
says they don't like this (by throwing an exception) then this
method will simply quit with that exception. That is, any engines
that come after than in the engine enumeration will not even be
told about this new bean.
<p>
So, in general its best to declare beans before the manager has
been asked to load any engines because then the user can be informed
when an engine rejects it. Also, its much more likely that an engine
can declare a bean at start time than it can at any time.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>beanName</CODE> - name to declare bean as<DD><CODE>bean</CODE> - the bean that's being declared<DD><CODE>type</CODE> - the type to represent the bean as
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if any of the languages that are already
running decides to throw an exception when asked to
declare this bean.</DL>
</DD>
</DL>
<HR>
<A NAME="eval(java.lang.String, java.lang.String, int, int, java.lang.Object)"><!-- --></A><H3>
eval</H3>
<PRE>
public java.lang.Object <B>eval</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object expr)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Evaluate the given expression of the given language and return the
resulting value.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>expr</CODE> - the expression to evaluate
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if anything goes wrong while running the script</DL>
</DD>
</DL>
<HR>
<A NAME="exec(java.lang.String, java.lang.String, int, int, java.lang.Object)"><!-- --></A><H3>
exec</H3>
<PRE>
public void <B>exec</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Execute the given script of the given language.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>script</CODE> - the script to execute
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if anything goes wrong while running the script</DL>
</DD>
</DL>
<HR>
<A NAME="iexec(java.lang.String, java.lang.String, int, int, java.lang.Object)"><!-- --></A><H3>
iexec</H3>
<PRE>
public void <B>iexec</B>(java.lang.String lang,
java.lang.String source,
int lineNo,
int columnNo,
java.lang.Object script)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Execute the given script of the given language, attempting to
emulate an interactive session w/ the language.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - language identifier<DD><CODE>source</CODE> - (context info) the source of this expression
(e.g., filename)<DD><CODE>lineNo</CODE> - (context info) the line number in source for expr<DD><CODE>columnNo</CODE> - (context info) the column number in source for expr<DD><CODE>script</CODE> - the script to execute
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if anything goes wrong while running the script</DL>
</DD>
</DL>
<HR>
<A NAME="getClassLoader()"><!-- --></A><H3>
getClassLoader</H3>
<PRE>
public java.lang.ClassLoader <B>getClassLoader</B>()</PRE>
<DL>
<DD>Get classLoader
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="getClassPath()"><!-- --></A><H3>
getClassPath</H3>
<PRE>
public java.lang.String <B>getClassPath</B>()</PRE>
<DL>
<DD>Get classPath
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="getLangFromFilename(java.lang.String)"><!-- --></A><H3>
getLangFromFilename</H3>
<PRE>
public static java.lang.String <B>getLangFromFilename</B>(java.lang.String fileName)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Determine the language of a script file by looking at the file
extension.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>fileName</CODE> - the name of the file
<DT><B>Returns:</B><DD>the scripting language the file is in if the file extension
is known to me (must have been registered via
registerScriptingEngine).
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if file's extension is unknown.</DL>
</DD>
</DL>
<HR>
<A NAME="getObjectRegistry()"><!-- --></A><H3>
getObjectRegistry</H3>
<PRE>
public <A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A> <B>getObjectRegistry</B>()</PRE>
<DL>
<DD>Return the current object registry of the manager.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the current registry.</DL>
</DD>
</DL>
<HR>
<A NAME="getTempDir()"><!-- --></A><H3>
getTempDir</H3>
<PRE>
public java.lang.String <B>getTempDir</B>()</PRE>
<DL>
<DD>Get tempDir
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="isLanguageRegistered(java.lang.String)"><!-- --></A><H3>
isLanguageRegistered</H3>
<PRE>
public static boolean <B>isLanguageRegistered</B>(java.lang.String lang)</PRE>
<DL>
<DD>Determine whether a language is registered.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - string identifying a language
<DT><B>Returns:</B><DD>true iff it is</DL>
</DD>
</DL>
<HR>
<A NAME="loadScriptingEngine(java.lang.String)"><!-- --></A><H3>
loadScriptingEngine</H3>
<PRE>
public <A HREF="../../../org/apache/bsf/BSFEngine.html" title="interface in org.apache.bsf">BSFEngine</A> <B>loadScriptingEngine</B>(java.lang.String lang)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Load a scripting engine based on the lang string identifying it.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - string identifying language
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if the language is unknown (i.e., if it
has not been registered) with a reason of
REASON_UNKNOWN_LANGUAGE. If the language is known but
if the interface can't be created for some reason, then
the reason is set to REASON_OTHER_ERROR and the actual
exception is passed on as well.</DL>
</DD>
</DL>
<HR>
<A NAME="lookupBean(java.lang.String)"><!-- --></A><H3>
lookupBean</H3>
<PRE>
public java.lang.Object <B>lookupBean</B>(java.lang.String beanName)</PRE>
<DL>
<DD>return a handle to a bean registered in the bean registry by the
application or a scripting engine. Returns null if bean is not found.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>beanName</CODE> - name of bean to look up
<DT><B>Returns:</B><DD>the bean if its found or null</DL>
</DD>
</DL>
<HR>
<A NAME="registerBean(java.lang.String, java.lang.Object)"><!-- --></A><H3>
registerBean</H3>
<PRE>
public void <B>registerBean</B>(java.lang.String beanName,
java.lang.Object bean)</PRE>
<DL>
<DD>Registering a bean allows a scripting engine or the application to
access that bean by name and to manipulate it.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>beanName</CODE> - name to register under<DD><CODE>bean</CODE> - the bean to register</DL>
</DD>
</DL>
<HR>
<A NAME="registerScriptingEngine(java.lang.String, java.lang.String, java.lang.String[])"><!-- --></A><H3>
registerScriptingEngine</H3>
<PRE>
public static void <B>registerScriptingEngine</B>(java.lang.String lang,
java.lang.String engineClassName,
java.lang.String[] extensions)</PRE>
<DL>
<DD>Register a scripting engine in the static registry of the
BSFManager.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>lang</CODE> - string identifying language<DD><CODE>engineClassName</CODE> - fully qualified name of the class interfacing
the language to BSF.<DD><CODE>extensions</CODE> - array of file extensions that should be mapped to
this language type. may be null.</DL>
</DD>
</DL>
<HR>
<A NAME="setClassLoader(java.lang.ClassLoader)"><!-- --></A><H3>
setClassLoader</H3>
<PRE>
public void <B>setClassLoader</B>(java.lang.ClassLoader classLoader)</PRE>
<DL>
<DD>Set the class loader for those that need to use it. Default is he
who loaded me or null (i.e., its Class.forName).
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>classLoader</CODE> - the class loader to use.</DL>
</DD>
</DL>
<HR>
<A NAME="setClassPath(java.lang.String)"><!-- --></A><H3>
setClassPath</H3>
<PRE>
public void <B>setClassPath</B>(java.lang.String classPath)</PRE>
<DL>
<DD>Set the classpath for those that need to use it. Default is the value
of the java.class.path property.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>classPath</CODE> - the classpath to use</DL>
</DD>
</DL>
<HR>
<A NAME="setObjectRegistry(org.apache.bsf.util.ObjectRegistry)"><!-- --></A><H3>
setObjectRegistry</H3>
<PRE>
public void <B>setObjectRegistry</B>(<A HREF="../../../org/apache/bsf/util/ObjectRegistry.html" title="class in org.apache.bsf.util">ObjectRegistry</A> objectRegistry)</PRE>
<DL>
<DD>Set the object registry used by this manager. By default a new
one is created when the manager is new'ed and this overwrites
that one.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>objectRegistry</CODE> - the registry to use</DL>
</DD>
</DL>
<HR>
<A NAME="setTempDir(java.lang.String)"><!-- --></A><H3>
setTempDir</H3>
<PRE>
public void <B>setTempDir</B>(java.lang.String tempDir)</PRE>
<DL>
<DD>Temporary directory to put stuff into (for those who need to). Note
that unless this directory is in the classpath or unless the
classloader knows to look in here, any classes here will not
be found! BSFManager provides a service method to load a class
which uses either the classLoader provided by the class loader
property or, if that fails, a class loader which knows to load from
the tempdir to try to load the class. Default value of tempDir
is "." (current working dir).
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>tempDir</CODE> - the temporary directory</DL>
</DD>
</DL>
<HR>
<A NAME="terminate()"><!-- --></A><H3>
terminate</H3>
<PRE>
public void <B>terminate</B>()</PRE>
<DL>
<DD>Gracefully terminate all engines
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="undeclareBean(java.lang.String)"><!-- --></A><H3>
undeclareBean</H3>
<PRE>
public void <B>undeclareBean</B>(java.lang.String beanName)
throws <A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></PRE>
<DL>
<DD>Undeclare a previously declared bean. This removes the bean from
the list of declared beans in the manager as well as asks every
running engine to undeclared the bean. As with above, if any
of the engines except when asked to undeclare, this method does
not catch that exception. Quietly returns if the bean is unknown.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>beanName</CODE> - name of bean to undeclare
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf">BSFException</A></CODE> - if any of the languages that are already
running decides to throw an exception when asked to
undeclare this bean.</DL>
</DD>
</DL>
<HR>
<A NAME="unregisterBean(java.lang.String)"><!-- --></A><H3>
unregisterBean</H3>
<PRE>
public void <B>unregisterBean</B>(java.lang.String beanName)</PRE>
<DL>
<DD>Unregister a previously registered bean. Silent if name is not found.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>beanName</CODE> - name of bean to unregister</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/BSFManager.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../org/apache/bsf/BSFException.html" title="class in org.apache.bsf"><B>PREV CLASS</B></A>
<A HREF="../../../org/apache/bsf/Main.html" title="class in org.apache.bsf"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html" target="_top"><B>FRAMES</B></A>
<A HREF="BSFManager.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
</BODY>
</HTML>
|