DataInputStream: method readLine() is deprecated. (What's the alternative?)

Hi there,
I have a DataInputStream object (code below). The code works great but I get a warning message below the code: dis.readLine()
The method readLine() from the type DataInputStream is deprecated
does anyone have an alternative to eliminate the warning?
DataInputStream dis = null;
String line = null;
//read
File f = new File(inputFolder+"/"+inputFileName);
FileInputStream fis = new FileInputStream(f);
BufferedInputStream bis = new BufferedInputStream(fis);
dis = new DataInputStream(bis); 
while ( (line=dis.readLine()) != null )
}

http://java.sun.com/j2se/1.4.2/docs/api/java/io/DataInputStream.html
readLine()
Deprecated. This method does not properly convert bytes to characters. As of JDK 1.1, the preferred way to read lines of text is via the BufferedReader.readLine() method. Programs that use the DataInputStream class to read lines can be converted to use the BufferedReader class by replacing code of the form:
DataInputStream d = new DataInputStream(in);
with:
BufferedReader d
= new BufferedReader(new InputStreamReader(in));

Similar Messages

  • What is the alternative for pneSearchDocProfiles  in UCM 11g

    Hi
    Any idea what is the alternative for the same in 11g? If I try the same code pneSearchDocProfiles.length always returns "0". As I can see pneCheckinDocProfiles and pneSearchDocProfiles are deprecated in 11g. I know these two are deprecated in 11g and part of deprecated.js file.
    Ashok

    Found the solution and we need use the below given code to find the length of the menu. There is no actual replacement for pneSearchDocProfile and pneCheckinDocProfile we need to use YUI libraries to get access to the menus. Below is the code
    var checkinmenu= YAHOO.widget.MenuManager.getMenu("MENU_A_NEW_CHECK_IN");
         var checkinmenuitems=checkinmenu.getItems();
    navBuilder.deleteItem("MY_PERSONAL_CHECKINS_" + (checkinmenuitems.length-1));
    var checkinmenu= YAHOO.widget.MenuManager.getMenu("MENU_A_SEARCH");
         var searchmenuitems=checkinmenu.getItems();
         navBuilder.deleteItem("MY_PERSONAL_SEARCHES_" + (searchmenuitems.length-1));

  • What is the alternative for DisplayMemberPath="Value" for Windows Store applications?

    I think there is a bug with Windows Store Applications when it comes to using DisplayMemberPath="Value".
    Here is my code
    <ComboBox Height="40" VerticalAlignment="Stretch" SelectedValuePath="Key" DisplayMemberPath="Value" x:Name="comboBox1" FontSize="25"/>
    var source = new Dictionary<string, double>();
    source.Add("Item1", 0.4);
    source.Add("Item2", 0.3);
    source.Add("Item3", 0.1);
    source.Add("Item4", 0.1);
    var formateDSource = new Dictionary<string, string>();
    foreach (var item in source)
    formateDSource.Add(string.Format("[{0}, {1}]", item.Key, item.Value), item.Key);
    comboBox1.ItemsSource = source;
    If you use this code in WPF in works perfectly. However if you use this code in a Windows Store Application then the Combo Box is empty and an error is thrown. So is there an alternative way to do this in Windows Store Applications and have I unearthed a
    bug? Because I have researched the Web for days and found no solution to this.*please do not comment unless you have tried my code as a Windows Store App not a WPF in Visual Studios. Can Someone post an example based on my code that works in Windows Store
    Apps please because this is terrible.
    Thanks

    It looks like you got an answer on SO:
    http://stackoverflow.com/questions/29817124/what-is-the-alternative-for-displaymemberpath-value-for-windows-store-applicat
    This does look like a bug.
    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.
    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined
    objects and unknown namespaces.

  • What's the alternative to losing everything?

    Guys I can't believe we lose all these features in iCloud, http://support.apple.com/kb/HT4898 – what is the alternative? Surely Mac would have one? I run 4 computers and need keychains, system preferences, signatures to all be in sync with each other MobileMe was perfect for this... if anyone has any ideas they would be very much appreciated!

    I can't believe that either, that's the only thing I've been using mobileMe for. IPersonally I can't see a single reason why I shoudl upgrade to iCloud.

  • How to export a PowerView report to Power Point in SharePoint Online? If it cannot be done,what is the alternative?

    How to export a PowerView report to Power Point in SharePoint Online? If it cannot be done,what is the alternative?

    Hi Tanay,
    I am not aware of a control you can put in PowerPoint, however, you can insert a web browser control and reference a page in SPO (or maybe even directly the path to the workbook, didn't try that).
    if you are using PowerPoint 2013 take a look
    here
    GALROY

  • What are the alternatives for BOM explosion?

    Hi.
    I am developing a report based on ck13n.I need the product costing of the Whole BOM upto the lowest level. right now i am js gettin the costing of the topmost heirarchy.Hw can i explode the BOM to the lowest level??? what are the alternatives?

    These are the userexits available for the BOM transactions CS11, CS12, CS13.
    Exit Name Description
    PCSD0001 Applications development R/3 BOMS
    PCSD0002 BOMs: Customer fields in item
    PCSD0003 BOMs: Customer fields in header
    PCSD0004 BOM comparison
    PCSD0005 BOMs: component check for material items
    PCSD0006 Mass changes user exit
    PCSD0007 Check changes in STKO
    PCSD0008 WBS BOM: Customer-specific explosion for creating
    PCSD0009 Order/WBS BOM, determine URL page
    PCSD0010 Order/WBS BOM, determine explosion date
    PCSD0011 Knowledge-based order BOM, parallel update
    PCSD0012 Customer - Mat. number/mat. number during material exchange
    PCSD0013 Customer-specific processing of an explosion for BOM browser
    PCSD0014 Knowledge-Based Order BOM: Status
    regards
    Abhay.
    <b>rewards point</b>

  • Is there a Pages for MAC OS 10.7.x? If not, what is the alternative? Concrete issue is that I have received a .pages document and need to edit. Many thanks

    Is there a Pages for MAC OS 10.7.x?
    If not, what is the alternative?
    Concrete issue is that I have received a ".pages" document and need to edit. I am running Mac Pro with OS X 10.7.
    Many thanks

    It is important that you determine if the .pages document originated from Pages ’08, Pages ’09, Pages v1.7.2 (IOS 6), or was exported as Pages ’09 from Pages v5+ on OS X Mavericks. If it meets one of these criteria, then you can edit the .pages document on your Lion machine with Pages ’09 from the iWork ’09 DVD. Pages documents can not be opened with TextEdit, but can be viewed with Preview.
    On the otherhand, if the .pages document was created with Pages for iCloud beta, Pages v2.2.1 (IOS 7), or Pages v5+ on Mavericks, then your only recourse is to edit the document with Pages for iCloud beta. Since Fall 2013, Apple changed the .pages document format into something even more malevolently proprietary. Apple word processing products since this timeframe, are subsets of the Pages ’09 features/functionality, and will filter out content they do not support.
    A Pages ’09 document is usually a compressed (zip) folder archive that looks like a regular file to the Finder. The newer Pages family of products only write out a package that to the Finder, also appears to be a regular file, but in reality it is a folder. The newer Pages documents must be zipped before placed on non-Apple filesystems.

  • Firefox OS Simulator 4.0 not available on Firefox 17.0 What is the alternative?

    Why isn't the Firefox OS Simulator 4.0 available on Firefox 17.0? When will it be available? What are the alternatives?

    Hello CKemp, Firefox OS Simulator 4.0 is the latest and works only with Firefox 19.0 and later, for the 17.0 firefox version only the Version 2.0.1 (and 2.0) works.
    sorry but i think the alternatives is to update firefox to latest version, so to work with the latest Firefox OS Simulator 4.0.
    are you talking about 17.0.8esr ?
    thank you

  • Icloud won't support iweb websites? What are the alternatives?

    iCloud won't support iweb websites? What are the alternatives?

    You may find this page helpful:
    http://rfwilmut.net/migrate2

  • If dont have ADOBE FLASH PLAYER... What is the alternative flash player for ipad mini and iphone

    If dont have ADOBE FLASH PLAYER...in mini ipad and iphone.. What is the alternative flash player for ipad mini and iphone

    There is no Flash for iOS and there never will be any Flash.
    Try the newer HTML5 versions of those Web sites that offer it.

  • What is the alternative to Ctr Alt Del to reboot OS or BIOS startup?

    On PCs running Windows you have the option of pressing Ctrl+Alt+Del to reboot the system while is booting up or while you are on BIOS. Also from within Windows you can perform the same combination to restart from a completely unresponsive OS. What is the OS X alternative to reboot from a stalled OS without having to press the power button?

    To the best of my knowledge there is no other method.
    Command-Option-Esc will allow you to kill a stalled process, but as far as I know, if Mac OS X is wedged, you power off the Mac by holding the power button for 10 seconds.

  • R12 plsql web toolkit disabled - what are the alternatives?

    We have developed a fair amount of add-on applications in our e-business suite using the plsql web toolkit (htp). This functionality has been disbaled in R12.
    My question to Oracle, "What is the work around for using applications we developed in 11i that were developed using the plsql web toolkit?
    Oracel response:
    R12 does not support WWK fucntions.
    You will need to recreate these as custom JSP pages.
    The pl/sql toolkit in the Apache Server is disabled in R12 as a security precaution.
    1. What are other people doing who have encountered this issue?
    2. Is it possible to enable the pl/sql toolkit in the apache server? If for nothing else than to buy time until these apps are re-written as jsp apps.
    3. Is anyone doing something other than jsp? i.e. SSWA Servlet Function?
    Any help or suggestions appreciated.

    Pl see if this link can help - http://blogs.oracle.com/stevenChan/2008/07/new_whitepaper_mod_plsql_and_e_1.html
    HTH
    Srini

  • PLSQL Web Toolkit disabled in R12 - What are the alternatives?

    We have developed a fair amount of add-on applications in our e-business suite using the plsql web toolkit (htp). This functionality has been disbaled in R12.
    My question to Oracle Support was , "What is the work around for using applications we developed in 11i that were developed using the plsql web toolkit?
    Oracle response:
    R12 does not support WWK fucntions.
    You will need to recreate these as custom JSP pages.
    The pl/sql toolkit in the Apache Server is disabled in R12 as a security precaution.
    1. What are other people doing who have encountered this issue?
    2. Is it possible to enable the pl/sql toolkit in the apache server? If for nothing else than to buy time until these apps are re-written as jsp apps.
    3. Is anyone doing something other than jsp? i.e. SSWA Servlet Function?
    Any help or suggestions appreciated.

    Steven, this is a re-post of a question I asked in your article
    http://blogs.oracle.com/stevenChan/2006/11/mod_plsql_not_supported_in_ebu.html
    (great stuff btw)
    Hoping others may see this and have some input as well. So.....
    As means to buy some time while we learn how to redevelop our existing extensions in the R12 OA Framework as jsp, we are exploring using mod_plsql on a separate Oracle Application Server 10g installation to extend the life of our applications written using the pl/sql web toolkit.
    So here is my question: How do you integrate applications using this seperate mod_plsql into R12's security since it does not allow you to register a function type WWK (SSWA plsql function)? i.e registering as an EBS function then adding to a menu and so on.
    Do you still register the function as a WWK (SSWA plsql function) and enter a fully qualified url to the mod_plsql pkg.proc in the Web HTML tab?
    Thanks for any comments.

  • What are the alternative technologies to create mobile website?

    I have never created a mobile website but have some experience using WML. I jst wanted to find what are the other alternatives and whether standard websites using php wouldn't work on mobile??
    Please let me know
    Thanks
    Uthay

    It's been my experience that many mobile phones lack certain client side technology support. By definition, server side technologies are not dependent on the client. Having said that, since we are on the Java forum I'll also suggest that Java itself has a lot of support on mobile phones (client side), so you could still have a lot of device support if you target that. For maximum support, I'd stick to server side for the complicated stuff.

  • "......not responding" even though I have!   What's the alternative?

    Hi
    I have a MacBook Pro, using broadband over a router, trying to use ichat with cam and just cannot get it to work -I just get the "XXXXX has not responded" - even if I have!
    On the same router I can use my Windows PC ok with MSN Msgr and web cam.
    I've read all the posts - what's the best alternative - aMSN?

    I have just entered the world of the doomed audio/video user and have spent an hour or so with a very helpful Apple operative, but still no fix yet. My audio/video worked fine on the router I have but within the last couple of weeks I have been getting an error message telling me that 'I' didn't respond to 'me', not that I didn't respond to someone else.
    Has anyone any idea what's going wrong, all the settings are the same as before and I can buddy chat etc., the only thing that might be different is that I've updated to 10.4.7. I have now been advised to stay at 10.4.6 and I'm going to try and chat with friends when they get in from work. Has anyone had the same problem and if so, did they get a fix?
    Every little bit of help would be most appreciated
    G5   Mac OS X (10.4.6)   was on 10.4.7

Maybe you are looking for

  • Currenc BAM (bosnia) is not in Table TCURR

    Hi Team, we have problem  ,   still we are maintaining BAM currency in TCURR table  but when we upload the data credit card details system shows error message " Currency BAM is not in Table TCURR   transaction were moved to table  PTRV_CCC for correc

  • Mapping multi-segment IDOC to multiple JDBC INSERT statements

    Hi Everyone, This is probably going to be easy for the experienced PI developers out there but I'm just starting out in this technology. We are running PI 1.11 and the scenario is as follows. We have a bespoke IDOC message type ZSTOCK which can conta

  • Espn web site rendered in a linear fashion

    The ESPN Mlb site is not rendered as it should. I have the problem in both normal and safe mode. For safe mode, I have copied the error console's error messages that are relevant to this in the troubleshooting buffer.

  • Using Union in a view. Each union references multiple DB links

    I want to make a view something like this: create vw_abc as select region_code, processing_status from region_control@uae union select region_code, processing_status from region_control@qatar The issue here is that the db links referenced are travers

  • Table editor row identification for an action on table row

    Hi Experts, I have a table editor with 5 columns and one of the column is a LinkToAction element. Now when i have multiple lines in this table, I want to know on action of click of the linktoaction of a particular row, i want the row number and its d