Modified | DDT |>| WED.OCT,971022,15:19-4 | | CoSy/Home ; CoSy/Current ; \/ \/ Bottom \/ \/ | © Coherent Systems Inc . |
============================: TUE.OCT,971021 :============================ |18:26| Java : Programing Language of Web ? . AndrewWright , NEC Res Inst Princton NJ . <wright@research.nj.nec.com> |18:40| Tek look @ Java : | In audience : 3 Java programmers , same C++ . lots C C . Me + 1 APL . Object oriented , Type-save . to write general apps & Web applets . Java programs run in Browser . Shipped accross net on demand . compiled to byte code ( like old Pascal P-code ) . can communicate . foundation for web programs : collaborative editors , newspapers . Unrelated : Javascript : can be embedded in wef pages & interpreted . was originally called LiveScript . ActiveX : MS framework for downloacing native machine code into browser . Offer similar capabilities as Java Applets but unrelated . Java as prog lang - advances over C , C++ . + Type-safety : run-time value must match compile time type . Widget w ; | w can only hold Widget enforced by Static typing & some dynamic checking & typing . Bounds chking . Type ð set of values cast m arrat access - perform runtime chking . + Abstraction - aids mngng cmplxity . class Point { private int x , y ; void move ( int dx ,dy ) { } } interface Widget { void move ( int dx ,dy ) ; } class Point Impelents Widget { ... } | implementor of Widget class Motion { void translate ( Widget w ) { .... } | client of Widget + Portability all programs have defined meaning . EVEN THOSE W ERRORS . ( Error behavior all defined . ) ' write once , run anywhere ' on JavaVirtualMachine . use commodity hardware . + Garbage Collection Drop pointer to object & its gone . automatic resource finalization of I/O ports , etc . Simplifies interfaces - no ownerhsip tracking - no manual reference counts . Essential for type-safety . Blamed for being really slow . Sun`s 10 yr old . copying collection of good stuff . + Exception handling . C++ now has - Code for handling errors can be localized . Raise exception rather than return status . avoids "forgot to chek return status" bugs . User code can handle system errors : eg %0 . array bounds violation . May be able to turn off some run time chks . Deficienies : Abstractions can be broken , has 'instanceof ' fn to determine type Can access memberf via reflection API No guarentee that clients don`t depend on interface implementation . Weak module sys . No Package interface . Packages can`t be nested . Complex semantics : class A { int f( int y ) { .. } . } | class B extend A { ... } Has Dynamic inheritance for methods , static for fields . Has no mathematicall definition . English specification is imprecise . implementers misinterpret . ( Standard ML is precise ) Can`t prove theorums abt language or programs - no parameterized classes . OOP for hetero collections , ~ homogeneous orderd . No Sort routines in Java Class Lib . Bell Labs extension : Pizza Wadler & Odersky , interface Ordered - implementations SLOW . 2-40 x slower than C . JustInTime Comipler produces native code frm byte : 2-10 x slower than C . Implementations are slowly improving . - No support for other paradigms - poor supoort fof procedural or functional programming . no data def facility . no convenient way to walk data structures . Designing w datatypes : Std ML example . datatype either behaviors or datatypes distributed accross objects . [ verb or noun centered ] Web programs . Running an applet . < applet code="TumbleItem.class" with = height= > < downlad byte-codes in TumbleItme.class Browser MUST guard against malicious applets . can have NO holes . [ nuff said ] run quicken . access others on your intranet . ( down hall have 10Mb cable modem ) Firewalls don`t help since still want to run Web . Applets run in 'sandbox' - can`t : read or write local disk , communicate w other servers , start other programs . Current browser Y JVM not robust . Depends on type-safety , byte-code verifyer , security of class-loader ( compler-time & run-time types of linked objs must match ) Depends on secure library routines : openURL getFont ( ..\..\*.* ) Netscape - 95 . DNS spoofing Java written in C . ActiveX bigger can of worms . Netscape & Explorer have no console showing running applets . ( may remain running ) . no audit trails . cryptograpy til `9705 . Sandboxing too restrictive . Want Digital Certificates . Ok to trust applet ? - all or nothing security . applet itself must be secure . Static analysis for security ( Andrew`s research ) - compile time analysis of info flow . info flow graph . eg : Show applet keeps inside data in , outside out . Security is a system wide problem . Proof carrying code ( Lee @ CMU ) program comes w machine- chekable proof of security properties . proofs . If download applet , full access like plug-ins . NOT ultimate language but better than C++ . Java & Web still young . |20:20| |20:25|I : Doesn`t change my initial view that Java moves the computing world forward a decade or so to where APL was in 1976 . Main advance : recognition of need for automatic memory management - garbage collection . ( C++ is an oxymoron trying to combine the notion of Objects with static memory allocation . ) What Java , and almost all other languages lack , is an understanding that the fundamental objects which must be manipulated are strings ( threads , vectors , sets ) of items . Their 'scalar' one-at-a-time approach ensures their inefficency .