Can anybody help me to build an interface that can work with this code

please help me to build an interface that can work with this code
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.FileReader;
public class Translate
public static void main(String [] args) throws IOException
if (args.length != 2)
System.err.println("usage: Translate wordmapfile textfile");
System.exit(1);
try
HashMap words = ReadHashMapFromFile(args[0]);
System.out.println(ProcessFile(words, args[1]));
catch (Exception e)
e.printStackTrace();
// static helper methods
* Reads a file into a HashMap. The file should contain lines of the format
* "key\tvalue\n"
* @returns a hashmap of the given file
@SuppressWarnings("unchecked")
private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
BufferedReader in = null;
HashMap map = null;
try
in = new BufferedReader(new FileReader(filename));
String line;
map = new HashMap();
while ((line = in.readLine()) != null)
String[] fields = line.split("
t", 2);
if (fields.length != 2) continue; //just ignore "invalid" lines
map.put(fields[0], fields[1]);
finally
if(in!=null) in.close(); //may throw IOException
return(map); //returning a reference to local variable is safe in java (unlike C/C++)
* Process the given file
* @returns String contains the whole file.
private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
BufferedReader in = null;
StringBuffer out = null;
try
in = new BufferedReader(new FileReader(filename));
out = new StringBuffer();
String line = null;
while( (line=in.readLine()) != null )
out.append(SearchAndReplaceWordsInText(words, line)+"\n");
finally
if(in!=null) in.close(); //may throw IOException
return out.toString();
* Replaces all occurrences in text of each key in words with it's value.
* @returns String
private static String SearchAndReplaceWordsInText(Map words, String text)
Iterator it = words.keySet().iterator();
while( it.hasNext() )
String key = (String)it.next();
text = text.replaceAll("\\b"key"
b", (String)words.get(key));
return text;
* @returns: s with the first letter capitalized
String capitalize(String s)
return s.substring(0,0).toUpperCase() + s.substring(1);
}... here's the head of my pirate_words_map.txt
hello               ahoy
hi                    yo-ho-ho
pardon me       avast
excuse me       arrr
yes                 aye
my                 me
friend             me bucko
sir                  matey
madam           proud beauty
miss comely    wench
where             whar
is                    be
are                  be
am                  be
the                  th'
you                 ye
your                yer
tell                be tellin'

please help me i don t know how to go about this.my teacher ask me to build an interface that work with the code .
Here is the interface i just build
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.FileReader;
import java.awt.*;
import javax.swing.*;
public class boy extends JFrame
JTextArea englishtxt;
JLabel head,privatetxtwords;
JButton translateengtoprivatewords;
Container c1;
public boy()
        super("HAKIMADE");
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        setBackground(Color.white);
        setLocationRelativeTo(null);
        c1 = getContentPane();
         head = new JLabel(" English to private talk Translator");
         englishtxt = new JTextArea("Type your text here", 10,50);
         translateengtoprivatewords = new JButton("Translate");
         privatetxtwords = new JLabel();
        JPanel headlabel = new JPanel();
        headlabel.setLayout(new FlowLayout(FlowLayout.CENTER));
        headlabel.add(head);
        JPanel englishtxtpanel = new JPanel();
        englishtxtpanel.setLayout(new FlowLayout(FlowLayout.CENTER,10,40));
        englishtxtpanel.add(englishtxt);
         JPanel panel1 = new JPanel();
         panel1.setLayout(new BorderLayout());
         panel1.add(headlabel,BorderLayout.NORTH);
         panel1.add(englishtxtpanel,BorderLayout.CENTER);
        JPanel translateengtoprivatewordspanel = new JPanel();
        translateengtoprivatewordspanel.setLayout(new FlowLayout(FlowLayout.CENTER,10,40));
        translateengtoprivatewordspanel.add(translateengtoprivatewords);
         JPanel panel2 = new JPanel();
         panel2.setLayout(new BorderLayout());
         panel2.add(translateengtoprivatewordspanel,BorderLayout.NORTH);
         panel2.add(privatetxtwords,BorderLayout.CENTER);
         JPanel mainpanel = new JPanel();
         mainpanel.setLayout(new BorderLayout());
         mainpanel.add(panel1,BorderLayout.NORTH);
         mainpanel.add(panel2,BorderLayout.CENTER);
         c1.add(panel1, BorderLayout.NORTH);
         c1.add(panel2);
public static void main(final String args[])
        boy  mp = new boy();
         mp.setVisible(true);
}..............here is the code,please make this interface work with the code
public class Translate
public static void main(String [] args) throws IOException
if (args.length != 2)
System.err.println("usage: Translate wordmapfile textfile");
System.exit(1);
try
HashMap words = ReadHashMapFromFile(args[0]);
System.out.println(ProcessFile(words, args[1]));
catch (Exception e)
e.printStackTrace();
// static helper methods
* Reads a file into a HashMap. The file should contain lines of the format
* "key\tvalue\n"
* @returns a hashmap of the given file
@SuppressWarnings("unchecked")
private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
BufferedReader in = null;
HashMap map = null;
try
in = new BufferedReader(new FileReader(filename));
String line;
map = new HashMap();
while ((line = in.readLine()) != null)
String[] fields = line.split("
t", 2);
if (fields.length != 2) continue; //just ignore "invalid" lines
map.put(fields[0], fields[1]);
finally
if(in!=null) in.close(); //may throw IOException
return(map); //returning a reference to local variable is safe in java (unlike C/C++)
* Process the given file
* @returns String contains the whole file.
private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
BufferedReader in = null;
StringBuffer out = null;
try
in = new BufferedReader(new FileReader(filename));
out = new StringBuffer();
String line = null;
while( (line=in.readLine()) != null )
out.append(SearchAndReplaceWordsInText(words, line)+"\n");
finally
if(in!=null) in.close(); //may throw IOException
return out.toString();
* Replaces all occurrences in text of each key in words with it's value.
* @returns String
private static String SearchAndReplaceWordsInText(Map words, String text)
Iterator it = words.keySet().iterator();
while( it.hasNext() )
String key = (String)it.next();
text = text.replaceAll("\\b"key"
b", (String)words.get(key));
return text;
* @returns: s with the first letter capitalized
String capitalize(String s)
return s.substring(0,0).toUpperCase() + s.substring(1);
}... here's the head of my pirate_words_map.txt
hello               ahoy
hi                    yo-ho-ho
pardon me       avast
excuse me       arrr
yes                 aye
my                 me
friend             me bucko
sir                  matey
madam           proud beauty
miss comely    wench
where             whar
is                    be
are                  be
am                  be
the                  th'
you                 ye
your                yer
tell                be tellin'

Similar Messages

  • Hello can anybody  help me to build an interface

    hello can you help me to build an interface that can work with this english to private talk converter code
    import java.util.Map;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.io.BufferedReader;
    import java.io.FileReader;
    public class Translate
    public static void main(String [] args) throws IOException
    if (args.length != 2)
    System.err.println("usage: Translate wordmapfile textfile");
    System.exit(1);
    try
    HashMap words = ReadHashMapFromFile(args[0]);
    System.out.println(ProcessFile(words, args[1]));
    catch (Exception e)
    e.printStackTrace();
    // static helper methods
    * Reads a file into a HashMap. The file should contain lines of the format
    * "key\tvalue\n"
    * @returns a hashmap of the given file
    @SuppressWarnings("unchecked")
    private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    HashMap map = null;
    try
    in = new BufferedReader(new FileReader(filename));
    String line;
    map = new HashMap();
    while ((line = in.readLine()) != null)
    String[] fields = line.split("\\t", 2);
    if (fields.length != 2) continue; //just ignore "invalid" lines
    map.put(fields[0], fields[1]);
    finally
    if(in!=null) in.close(); //may throw IOException
    return(map); //returning a reference to local variable is safe in java (unlike C/C++)
    * Process the given file
    * @returns String contains the whole file.
    private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    StringBuffer out = null;
    try
    in = new BufferedReader(new FileReader(filename));
    out = new StringBuffer();
    String line = null;
    while( (line=in.readLine()) != null )
    out.append(SearchAndReplaceWordsInText(words, line)+"\n");
    finally
    if(in!=null) in.close(); //may throw IOException
    return out.toString();
    * Replaces all occurrences in text of each key in words with it's value.
    * @returns String
    private static String SearchAndReplaceWordsInText(Map words, String text)
    Iterator it = words.keySet().iterator();
    while( it.hasNext() )
    String key = (String)it.next();
    text = text.replaceAll("\\b"+key+"\\b", (String)words.get(key));
    return text;
    * @returns: s with the first letter capitalized
    String capitalize(String s)
    return s.substring(0,0).toUpperCase() + s.substring(1);
    ... here's the head of my pirate_words_map.txt
    hello     ahoy
    hi     yo-ho-ho
    pardon me     avast
    excuse me     arrr
    yes     aye
    my     me
    friend     me bucko
    sir     matey
    madam     proud beauty
    miss     comely wench
    stranger     scurvy dog
    officer     foul blaggart
    where     whar
    is     be
    are     be
    am     be
    the     th'
    you     ye
    your     yer
    tell     be tellin'

    hakimade wrote:
    hello can you help me to build an interface that can work with this english to private talk converter codeYou might want to re-ask this question in such a way that it can be answered.
    Also, when posting your code, please use code tags so that your code will retain its formatting and be readable. To do this, either use the "code" button at the top of the forum Message editor or place the tag [code] at the top of your block of code and the tag [/code] at the bottom, like so:
    [code]
      // your code block goes here.
      // note the differences between the tag at the top vs the bottom.
    [/code]or
    {code}
      // your code block goes here.
      // note here that the tags are the same.
    {code}Good luck.

  • HT2693 My UPAD lite does not start after recent update. I have lots of info in it. Can anybody help me to get it back. Can I get the update out somehow? Thanks

    My UPAD lite does not start after recent update. I have lots of info in it. Can anybody help me to get it back? Can I somehow undo the update? Thanks

    "UPAD lite?"
    I expect that you mean some version of iPad.
    First, try a system reset.  It cures many ills and it's quick, easy and harmless...
    Hold down the on/off switch and the Home button simultaneously until the screen blacks out or you see the Apple logo.  Ignore the "Slide to power off" text if it appears.  You will not lose any apps, data, music, movies, settings, etc.
    If the Reset doesn't work, try a Restore.  Note that it's nowhere near as quick as a Reset.  Connect via cable to the computer that you use for sync.  From iTunes, select the iPad/iPod and then select the Summary tab.  Follow directions for Restore and be sure to say "yes" to the backup.  You will be warned that all data (apps, music, movies, etc.) will be erased but, as the Restore finishes, you will be asked if you wish the contents of the backup to be copied to the iPad/iPod.  Again, say "yes."
    At the end of the basic Restore, you will be asked if you wish to sync the iPad/iPod.  As before, say "yes."  Note that that sync selection will disappear and the Restore will end if you do not respond within a reasonable time.  If that happens, only the apps that are part of the IOS will appear on your device.  Corrective action is simple -  choose manual "Sync" from the bottom right of iTunes.
    If you're unable to do the Restore, go into Recovery Mode per the instructions here.

  • Why can't I interrupt the main thread from a child thread with this code?

    I am trying to find an elegant way for a child thread (spawned from a main thread) to stop what its doing and tell the main thread something went wrong. I thought that if I invoke mainThread.interrupt() from the child thread by giving the child thread a reference to the main thread, that would do the trick. But it doesn't work all the time. I want to know why. Here's my code below:
    The main class:
    * IF YOU RUN THIS OFTEN ENOUGH, YOU'LL NOTICE THE "Child Please!" MESSAGE NOT SHOW AT SOME POINT. WHY?
    public class InterruptingParentFromChildThread
         public static void main( String args[] )
              Thread child = new Thread( new ChildThread( Thread.currentThread() ) );
              child.start();
              try
                   child.join();
              catch( InterruptedException e )
    // THE LINE BELOW DOESN'T GET PRINTED EVERY SINGLE TIME ALTHOUGH IT WORKS MOST TIMES, WHY?
                   System.out.println( "Child please!" );
              System.out.println( "ALL DONE!" );
    The class for the child thread:
    public class ChildThread implements Runnable
         Thread mParent;
         public ChildThread( Thread inParent )
              mParent = inParent;
         public void run()
              System.out.println( "In child thread." );
              System.out.println( "Let's interrupt the parent thread now." );
              // THE COMMENTED OUT LINE BELOW, IF UNCOMMENTED, DOESN'T INVOKE InterruptedException THAT CAN BE CAUGHT IN THE MAIN CLASS' CATCH BLOCK, WHY?
              //Thread.currentThread().interrupt();
              // THIS LINE BELOW ONLY WORKS SOMETIMES, WHY?
              mParent.interrupt();
    }

    EJP wrote:
    I'm not convinced about that. The wording in join() suggests that, but the wording in interrupt() definitely does not.Thread.join() doesn't really provide much in the way of details, but Object.wait() does:
    "throws InterruptedException - if any thread interrupted the current thread +before+ or while the current thread was waiting for a notification. The interrupted status of the current thread is cleared when this exception is thrown."
    every jdk method i've used which throws InterruptedException will always throw if entered while a thread is currently interrupted. admitted, i rarely use Thread.join(), so it's possible that method could be different. however, that makes the thread interruption far less useful if it's required to hit the thread while it's already paused.
    a simple test with Thread.sleep() confirms my expected behavior (sleep will throw):
    Thread.currentThread().interrupt();
    Thread.sleep(1000L);

  • Can anybody help me, a layman in Apple, to input Chinese with iPad?

    I notice there are a few options in keyboard setup...I chose Pinyin keyboard, but after that nothing happened. I typed pinyin through my keyboard but no Chinese charaters showed. What should I do next? or, Did I do something wrong?

    I saw the globe, thank you. By tapping it I could use different input methods, it works like a magic.
    Thank you for the help, now I can type Chinese, and even write it on the keyboard.

  • Why i can't buy anything from my games with my redeemed dollar? Isn't it possible? Can anybody help me!!!, Why i can't buy anything from my games with my redeemed dollar? Isn't it possible? Can anybody help me!!!

    I redeem 10$ . I can buy app from app store but i can't buy any thing from my games. Such as i play hay day games and i want to buy some diamond by this dollar. But i can not buy. Why?? Pls some one tell me.

    What happens when you try?
    Some countries charge tax that is not included in the iTunes/App store listed price.

  • Can Apple Store unlock my Iphone 4 so that it works with T-Mobile service

    Can I get my Iphone 4 unlocked from ATT service to use with T-Mobile service?

    Obviously that answer is now out-of-date.
    I was simply trying to help someone.  What value did your responses provide to the actual question asked? 
    Seems like you are both responding with nit picky comments because this forum is probably your entire life and you love to argue the infinite details of why anyone can post on a PUBLIC forum without being picked apart by uber nerds.
    ANY response to THIS post will certainly prove it. 

  • I need help in getting a flash player that will work with my older MAC.

    Help!

    Is that a Power PC?  See What version of Flash Player should I use with my Power PC based Mac?

  • I've connected my device through a wifi network and i accidentally signed out my apple ID for imessage then when I signed back in i cant seem to get connected though my wifi connection is working just fine. can anybody help me?

    I've connected my device through a wifi network and i accidentally signed out my apple ID for imessage then when I signed back in i cant seem to get connected though my wifi connection is working just fine. can anybody help me?

    I am having the same problem with my ipod nano
    I have been trying since Xmas

  • TS1559 After performing a software restore in iTunes, the problems remains... I still cannot turn Wifi on as it is still greyed out??? Can anybody help please?

    Have performed software restore and still I am unable to turn my wifi on as the option to turn on is greyed out???
    Can anybody help?.

    If no change after restoring the iPhone with iTunes as a new iPhone or not from the backup, make an appointment at an Apple Store if there is one nearby since this is a hardware problem.

  • I am facing problem regarding graphical user interface. I am using text box for editing files. I want to show the line numbers and graphical breakpoint​s along with text box. Can anybody help me in this? Thanks.

    I am facing problem regarding graphical user interface. I am using text box for editing files. I want to show the line numbers and graphical breakpoints along with text box. Can anybody help me in this? Thanks.

    Thanks for you reply.
    But actually I don't want to show the \ (backslashes) to the user in my text box. 
    Ok let me elaborate this problem little more. 
    I want to show my text box as it is in normal editors e.g. In Matlab editor. There is a text box and on left side the gray bar shows the line numbers corresponding to the text. Further more i want that the user should be able to click on any line number to mark specific line as breakpoint (red circle or any graphical indication for mark). 
    Regards,
    Waqas Ahmad

  • Hi all! I was updating the software on i pad to ios6, update was interrupted(apple update server is unavailable...). iTunes Diagnostics shows that "secure link to I tunes store failed". I use Windows 7 Home Premium 64 bit. Can anybody help please?

    Hi all! I was updating the software on i pad to ios6, update was interrupted(apple update server is unavailable...). iTunes Diagnostics shows that "secure link to I tunes store failed". I use Windows 7 Home Premium 64 bit. Can anybody help please?
    The following was done so far:
    1. Windows Firewall - new rule created for itunes.
    2. iTunes - latest version installed.
    3. LAN setting : automatic detection of proxy is enabled;
    4. iTunes diagnostics shows:
    Microsoft Windows 7 x64 Home Premium Edition (Build 7600)
    TOSHIBA Satellite L655
    iTunes 11.0.2.26
    QuickTime 7.7.3
    FairPlay 2.3.31
    Apple Application Support 2.3.3
    iPod Updater Library 10.0d2
    CD Driver 2.2.3.0
    CD Driver DLL 2.1.3.1
    Apple Mobile Device 6.1.0.13
    Apple Mobile Device Driver 1.64.0.0
    Bonjour 3.0.0.10 (333.10)
    Gracenote SDK 1.9.6.502
    Gracenote MusicID 1.9.6.115
    Gracenote Submit 1.9.6.143
    Gracenote DSP 1.9.6.45
    iTunes Serial Number 003FB880034B7720
    Current user is not an administrator.
    The current local date and time is 2013-04-23 11:01:14.
    iTunes is not running in safe mode.
    WebKit accelerated compositing is enabled.
    HDCP is supported.
    Core Media is supported.
    Video Display Information
    Intel Corporation, Intel(R) HD Graphics
    **** External Plug-ins Information ****
    No external plug-ins installed.
    iPodService 11.0.2.26 (x64) is currently running.
    iTunesHelper 11.0.2.26 is currently running.
    Apple Mobile Device service 3.3.0.0 is currently running.
    **** Network Connectivity Tests ****
    Network Adapter Information
    Adapter Name:          {1CB5BBC2-8124-4664-899A-CE0A4683E3B4}
    Description:          Realtek RTL8188CE Wireless LAN 802.11n PCI-E NIC
    IP Address:          0.0.0.0
    Subnet Mask:          0.0.0.0
    Default Gateway:          0.0.0.0
    DHCP Enabled:          Yes
    DHCP Server:
    Lease Obtained:          Thu Jan 01 08:00:00 1970
    Lease Expires:          Thu Jan 01 08:00:00 1970
    DNS Servers:
    Adapter Name:          {8140112A-43D0-41D6-8B36-BE146C811173}
    Description:          Atheros AR8152/8158 PCI-E Fast Ethernet Controller (NDIS 6.20)
    IP Address:          10.5.7.196
    Subnet Mask:          255.255.0.0
    Default Gateway:          10.5.0.1
    DHCP Enabled:          Yes
    DHCP Server:          172.18.255.2
    Lease Obtained:          Tue Apr 23 10:14:40 2013
    Lease Expires:          Tue Apr 23 22:14:40 2013
    DNS Servers:          121.97.59.7
                        121.97.59.2
                        121.97.59.3
    Active Connection:          LAN Connection
    Connected:          Yes
    Online:                    Yes
    Using Modem:          No
    Using LAN:          Yes
    Using Proxy:          No
    Firewall Information
    Windows Firewall is on.
    iTunes is NOT enabled in Windows Firewall.
    Connection attempt to Apple web site was successful.
    Connection attempt to browsing iTunes Store was unsuccessful.
    The network connection timed out.
    Connection attempt to purchasing from iTunes Store was successful.
    Connection attempt to iPhone activation server was successful.
    Connection attempt to firmware update server was unsuccessful.
    The network connection timed out.
    Connection attempt to Gracenote server was successful.
    The network connection timed out.
    Last successful iTunes Store access was 2013-03-22 10:05:31.
    @@@. iTunes IS ENABLED THROUGH THE FIREWALL , even though diagnostics says "NOT enabled"

    hours after the first post i somehow got this to work. dont know how, but i do tried the dns clear cache, the clear host file, oh and i did the check automatically detech dns AND THEN se-check it again before i got this to work.

  • Can anybody help? My Safari browser keeps crashing. The whole window just turns grey.

    Can anybody help? My Safari browser keeps crashing on iMac 10.7.5. The whole window just turns grey. It started happening around the time of the new bookmarks menu upgrade recently which changed the bookmarks to be only on the side and makes it so you can see all your bookmarks while browsing.  I know I have a lot of bookmarks, so I tried hiding them, but it still happens. I ALREADY TRIED CLEARING MY HISTORY, AND THAT DID NOT HELP, AND I HAVE NO EXTENSIONS FOR THIS BROWSER.
    Does the fact that I am in Brasil have anything to do with it?
    Thank you to anyone who can help. In case no one can come up with an answer, is there an easy way to transfer my bookmarks from safari to either firefox or chrome?
    Much appreciated.

    1. This is a comment on what you should and should not do to protect yourself from malicious software ("malware") that circulates on the Internet. It does not apply to software, such as keystroke loggers, that may be installed deliberately by an intruder who has hands-on access to the victim's computer. That threat is in a different category, and there's no easy way to defend against it. If you have reason to suspect that you're the target of such an attack, you need expert help.
    If you find this comment too long or too technical, read only sections 5, 6, and 10.
    OS X now implements three layers of built-in protection specifically against malware, not counting runtime protections such as execute disable, sandboxing, system library randomization, and address space layout randomization that may also guard against other kinds of exploits.
    2. All versions of OS X since 10.6.7 have been able to detect known Mac malware in downloaded files, and to block insecure web plugins. This feature is transparent to the user, but internally Apple calls it "XProtect." The malware recognition database is automatically checked for updates once a day; however, you shouldn't rely on it, because the attackers are always at least a day ahead of the defenders.
    The following caveats apply to XProtect:
    It can be bypassed by some third-party networking software, such as BitTorrent clients and Java applets.
    It only applies to software downloaded from the network. Software installed from a CD or other media is not checked.
    As new versions of OS X are released, it's not clear whether Apple will indefinitely continue to maintain the XProtect database of older versions such as 10.6. The security of obsolete system versions may eventually be degraded. Security updates to the code of obsolete systems will stop being released at some point, and that may leave them open to other kinds of attack besides malware.
       3. Starting with OS X 10.7.5, there has been a second layer of built-in malware protection, designated "Gatekeeper" by Apple. By default, applications and Installer packages downloaded from the network will only run if they're digitally signed by a developer with a certificate issued by Apple. Software certified in this way hasn't necessarily been tested by Apple, but you can be reasonably sure that it hasn't been modified by anyone other than the developer. His identity is known to Apple, so he could be held legally responsible if he distributed malware. That may not mean much if the developer lives in a country with a weak legal system (see below.)
    Gatekeeper doesn't depend on a database of known malware. It has, however, the same limitations as XProtect, and in addition the following:
    It can easily be disabled or overridden by the user.
    A malware attacker could get control of a code-signing certificate under false pretenses, or could simply ignore the consequences of distributing codesigned malware.
    An App Store developer could find a way to bypass Apple's oversight, or the oversight could fail due to human error.
    For the reasons given above, App Store products, and other applications recognized by Gatekeeper as signed, are safer than others, but they can't be considered absolutely safe. "Sandboxed" applications may prompt for access to private data, such as your contacts, or for access to the network. Think before granting that access. OS X security is based on user input. Never click through any request for authorization without thinking.
    4. Starting with OS X 10.8.3, a third layer of protection has been added: a "Malware Removal Tool" (MRT). MRT runs automatically in the background when you update the OS. It checks for, and removes, malware that may have evaded the other protections via a Java exploit (see below.) MRT also runs when you install or update the Apple-supplied Java runtime (but not the Oracle runtime.) Like XProtect, MRT is effective against known threats, but not against unknown ones. It notifies you if it finds malware, but otherwise there's no user interface to MRT.
    5. The built-in security features of OS X reduce the risk of malware attack, but they're not absolute protection. The first and best line of defense is always going to be your own intelligence. With the possible exception of Java exploits, all known malware circulating on the Internet that affects a fully-updated installation of OS X 10.6 or later takes the form of so-called "Trojan horses," which can only have an effect if the victim is duped into running them. The threat therefore amounts to a battle of wits between you and the malware attacker. If you're smarter than he thinks you are, you'll win.
    That means, in practice, that you always stay within a safe harbor of computing practices. How do you know what is safe?
    Any website that prompts you to install a “codec,” “plug-in,” "player," "extractor," or “certificate” that comes from that same site, or an unknown one, is unsafe.
    A web operator who tells you that you have a “virus,” or that anything else is wrong with your computer, or that you have won a prize in a contest you never entered, is trying to commit a crime with you as the victim. (Some reputable websites did legitimately warn visitors who were infected with the "DNSChanger" malware. That exception to this rule no longer applies.)
    Pirated copies or "cracks" of commercial software, no matter where they come from, are unsafe.
    Software of any kind downloaded from a BitTorrent or from a Usenet binary newsgroup is unsafe.
    Software that purports to help you do something that's illegal or that infringes copyright, such as saving streamed audio or video for reuse without permission, is unsafe. All YouTube "downloaders" are outside the safe harbor, though not all are necessarily harmful.
    Software with a corporate brand, such as Adobe Flash Player, must be downloaded directly from the developer’s website. If it comes from any other source, it's unsafe. For instance, if a web page warns you that Flash is out of date, do not follow an offered link to an update. Go to the Adobe website to download it, if you need it at all.
    Even signed applications, no matter what the source, should not be trusted if they do something unexpected, such as asking for permission to access your contacts, your location, or the Internet for no obvious reason.
    "FREE WI-FI !!!" networks in public places are unsafe unless you can verify that the network is not a trap (which you probably can't.) Even then, do not download any software or transmit any private information while connected to such a network, regardless of where it seems to come from or go to.
    6. Java on the Web (not to be confused with JavaScript, to which it's not related, despite the similarity of the names) is a weak point in the security of any system. Java is, among other things, a platform for running complex applications in a web page, on the client. That was always a bad idea, and Java's developers have proven themselves incapable of implementing it without also creating a portal for malware to enter. Past Java exploits are the closest thing there has ever been to a Windows-style virus affecting OS X. Merely loading a page with malicious Java content could be harmful.
    Fortunately, client-side Java on the Web is obsolete and mostly extinct. Only a few outmoded sites still use it. Try to hasten the process of extinction by avoiding those sites, if you have a choice. Forget about playing games or other non-essential uses of Java.
    Java is not included in OS X 10.7 and later. Discrete Java installers are distributed by Apple and by Oracle (the developer of Java.) Don't use either one unless you need it. Most people don't. If Java is installed, disable it — not JavaScript — in your browsers.
    Regardless of version, experience has shown that Java on the Web can't be trusted. If you must use a Java applet for a task on a specific site, enable Java only for that site in Safari. Never enable Java for a public website that carries third-party advertising. Use it only on well-known, login-protected, secure websites without ads. In Safari 6 or later, you'll see a lock icon in the address bar with the abbreviation "https" when visiting a secure site.
    Follow the above guidelines, and you’ll be as safe from malware as you can practically be. The rest of this comment concerns what you should not do to protect yourself from malware.
    7. Never install any commercial "anti-virus" or "Internet security" products for the Mac, as they all do more harm than good, if they do any good at all. Any database of known threats is always going to be out of date. Most of the danger is from unknown threats. If you need to be able to detect Windows malware in your files, use one of the free anti-virus products in the Mac App Store — nothing else.
    Why shouldn't you use commercial "anti-virus" products?
    Their design is predicated on the nonexistent threat that malware may be injected at any time, anywhere in the file system. Malware is downloaded from the network; it doesn't materialize from nowhere.
    In order to meet that nonexistent threat, the software modifies or duplicates low-level functions of the operating system, which is a waste of resources and a common cause of instability, bugs, and poor performance.
    To recognize malware, the software depends on a database of known threats, which is always at least a day out of date. Most of the real-world danger of malware attack comes from highly targeted "zero-day" exploits that are not yet recognized.
    By modifying the operating system, the software itself may create weaknesses that could be exploited by malware attackers.
    8. An anti-malware product from the App Store, such as "ClamXav," doesn't have these drawbacks. That doesn't mean it's entirely safe. It may report email messages that have "phishing" links in the body, or Windows malware in attachments, as infected files, and offer to delete or move them. Doing so will corrupt the Mail database. The messages should be deleted from within the Mail application.
    An anti-virus app is not needed, and should not be relied upon, for protection against OS X malware. It's useful only for detecting Windows malware. Windows malware can't harm you directly (unless, of course, you use Windows.) Just don't pass it on to anyone else.
    A Windows malware attachment in email is usually easy to recognize. The file name will often be targeted at people who aren't very bright; for example:
    ♥♥♥♥♥♥♥♥♥♥♥♥♥♥!!!!!!!H0TBABEZ4U!!!!!!!.AVI♥♥♥♥♥♥♥♥♥♥♥♥♥♥.exe
    Anti-virus software may be able to tell you which particular virus or trojan it is, but do you care? In practice, there's seldom a reason to use the software unless a network administrator requires you to do it.
    The ClamXav developer won't try to "upsell" you to a paid version of the product. Other developers may do that. Don't be upsold. For one thing, you should not pay to protect Windows users from the consequences of their choice of computing platform. For another, a paid upgrade from a free app will probably have the disadvantages mentioned in section 7.
    9. It seems to be a common belief that the built-in Application Firewall acts as a barrier to infection, or prevents malware from functioning. It does neither. It blocks inbound connections to certain network services you're running, such as file sharing. It's disabled by default and you should leave it that way if you're behind a router on a private home or office network. Activate it only when you're on an untrusted network, for instance a public Wi-Fi hotspot, where you don't want to provide services. Disable any services you don't use in the Sharing preference pane. All are disabled by default.
    10. As a Mac user you don't have to live in fear that your computer is going to be infected every time you install an application, read email, or visit a web page. But neither should you have the false idea that you will always be safe, no matter what you do. The greatest harm done by security software is precisely its selling point: it makes people feel safe. They may then feel safe enough to take risks from which the software doesn't protect them. Nothing can lessen the need for safe computing practices.

  • Can anybody help me in order to decide API or import program

    Can anybody help me in order to decide API or import program while updating the seeded table qa_results.
    Also keen to know whether can i use return in the worflow package?
    Regards,
    Javed Khan

    Hi Javed,
    refer MOS note:
    Need Help For Oracle Quality Open Interfaces And APIs [ID 1366416.1]
    also review below note as number of ERs are already raised for Quality Results
    Answers to Discrete Quality --> Frequently asked questions [ID 1065716.1]
    thanks

  • I cannot open iCal because of a problem. Can anybody help me? The computer will not allow it to open and sends a message to apple each time. The icon has gone from the dock, but ical works on my iPad and I am afraid to sync it with my computer.?

    I cannot open iCal because of a problem. Can anybody help me? The computer will not allow it to open and sends a message to apple each time. The icon has gone from the dock, but ical works on my iPad and I am afraid to sync it with my computer in case it wipes everything .

    I have the exact same problem. I have not changed anything. This is probably a bug or something that has gone bad with Mac OS X (10.7.2). I have not found any solution for this on the web.
    MacBook Pro, Mac OS X (10.7.2).

Maybe you are looking for

  • Formula line in Report painter

    Hello, Can I use 'IF' phrase in Formula column in Report painter ?  If so what's the right Syntax . Thank you, Ran.

  • Issue while using CountNode()

    Hi All, I am stuck at this issue:- I am using a file adapter to read a file which has some repeated tags and I want to count the number of repeated nodes.I came across this function and used in my code. But instead of given the total count of the nod

  • Condition value of Tax condition type gets added to Total Value in Contract

    Hi All, I'm currently investigating an issue where there are 2 line items in an SAP Sales Contract. There is a human error in the second line where the billing end date is less than billing start date in the billing plan.  Consequently, the second li

  • More song in imatch then on computer

    I been downloading music on to my computer and using the imatch.  it has always been a even match of number of songs on my computer compared to the my imatch.  All of sudden i have more song in my imatch then i do on my computer.  Is there a way to d

  • Detect frequency of an analog signal coming in through myRIo AudioIn analog port

    I am working on a fire-fighting robot that runs using myRio. I have a small mic plugged into the 'AudioIn' port of the myRIO and the robot has to detect a certain frequency(2.8 or 3.5 KHz) to start navigation. The AnalogIn express VI gives me raw vol