{"id":26743,"date":"2021-04-30T23:10:06","date_gmt":"2021-05-01T03:10:06","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/recent-posts\/threadedechoserver-java-a-multithreaded-version-of-echoserver-where-each-client-request-is-serviced-on-a-separate-thread-requires-the-following-classes-programming-code-examples-java-j2ee-j2me\/"},"modified":"2021-04-30T23:10:06","modified_gmt":"2021-05-01T03:10:06","slug":"threadedechoserver-java-a-multithreaded-version-of-echoserver-where-each-client-request-is-serviced-on-a-separate-thread-requires-the-following-classes-programming-code-examples-java-j2ee-j2me","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=26743","title":{"rendered":"ThreadedEchoServer.java  A multithreaded version of EchoServer, where each client request is serviced on a separate thread. Requires the following classes: #Programming Code Examples #Java\/J2EE\/J2ME #Network Programming"},"content":{"rendered":"<pre>\nThreadedEchoServer.java  A multithreaded version of EchoServer, where each client request is serviced on a separate thread. Requires the following classes: \n\n\nimport java.net.*;\nimport java.io.*;\n\n\/** A multithreaded variation of EchoServer.\n *\n *  Taken from Core Web Programming from\n *  Prentice Hall and Sun Microsystems Press,\n *  .\n *  &copy; 2001 Marty Hall and Larry Brown;\n *  may be freely used or adapted.\n *\/\n\npublic class ThreadedEchoServer extends EchoServer\n                                implements Runnable {\n  public static void main(String[] args) {\n    int port = 8088;\n    if (args.length &gt; 0) {\n      try {\n        port = Integer.parseInt(args[0]);\n      } catch(NumberFormatException nfe) {}\n    }\n    ThreadedEchoServer echoServer =\n      new ThreadedEchoServer(port, 0);\n    echoServer.serverName = &quot;Threaded EchoServer&quot;;\n  }\n\n  public ThreadedEchoServer(int port, int connections) {\n    super(port, connections);\n  }\n\n  \/** The new version of handleConnection starts a thread. This\n   *  new thread will call back to the <i>old<\/i> version of\n   *  handleConnection, resulting in the same server behavior\n   *  in a multithreaded version. The thread stores the Socket\n   *  instance since run doesn't take any arguments, and since\n   *  storing the socket in an instance variable risks having\n   *  it overwritten if the next thread starts before the run\n   *  method gets a chance to copy the socket reference.\n   *\/\n\n  public void handleConnection(Socket server) {\n    Connection connectionThread = new Connection(this, server);\n    connectionThread.start();\n  }\n\n  public void run() {\n    Connection currentThread =\n      (Connection)Thread.currentThread();\n    try {\n      super.handleConnection(currentThread.getSocket());\n    } catch(IOException ioe) {\n      System.out.println(&quot;IOException: &quot; + ioe);\n      ioe.printStackTrace();\n    }\n  }\n}\n\n\/** This is just a Thread with a field to store a Socket object.\n *  Used as a thread-safe means to pass the Socket from\n *  handleConnection to run.\n *\/\n\nclass Connection extends Thread {\n  private Socket serverSocket;\n\n  public Connection(Runnable serverObject,\n                    Socket serverSocket) {\n    super(serverObject);\n    this.serverSocket = serverSocket;\n  }\n\n  public Socket getSocket() {\n    return serverSocket;\n  }\n}\n\n\n\nEchoServer.java  Creates a Web page showing all data sent from the client (browser). \n\n\nimport java.net.*;\nimport java.io.*;\nimport java.util.StringTokenizer;\n\n\/** A simple HTTP server that generates a Web page showing all\n *  of the data that it received from the Web client (usually\n *  a browser). To use this server, start it on the system of\n *  your choice, supplying a port number if you want something\n *  other than port 8088. Call this system server.com. Next,\n *  start a Web browser on the same or a different system, and\n *  connect to http:\/\/server.com:8088\/whatever. The resultant\n *  Web page will show the data that your browser sent. For \n *  debugging in servlet or CGI programming, specify \n *  http:\/\/server.com:8088\/whatever as the ACTION of your HTML\n *  form. You can send GET or POST data; either way, the\n *  resultant page will show what your browser sent.\n *\n *  Taken from Core Web Programming from \n *  Prentice Hall and Sun Microsystems Press,\n *  &copy; 2001 Marty Hall and Larry Brown;\n *  may be freely used or adapted. \n *\/\n\npublic class EchoServer extends NetworkServer {\n  protected int maxRequestLines = 50;\n  protected String serverName = &quot;EchoServer&quot;;\n\n  \/** Supply a port number as a command-line\n   *  argument. Otherwise, use port 8088.\n   *\/\n  \n  public static void main(String[] args) {\n    int port = 8088;\n    if (args.length &gt; 0) {\n      try {\n        port = Integer.parseInt(args[0]);\n      } catch(NumberFormatException nfe) {}\n    }\n    new EchoServer(port, 0);\n  }\n\n  public EchoServer(int port, int maxConnections) {\n    super(port, maxConnections);\n    listen();\n  }\n\n  \/** Overrides the NetworkServer handleConnection method to \n   *  read each line of data received, save it into an array\n   *  of strings, then send it back embedded inside a PRE \n   *  element in an HTML page.\n   *\/\n  \n  public void handleConnection(Socket server)\n      throws IOException{\n    System.out.println\n        (serverName + &quot;: got connection from &quot; +\n         server.getInetAddress().getHostName());\n    BufferedReader in = SocketUtil.getReader(server);\n    PrintWriter out = SocketUtil.getWriter(server);\n    String[] inputLines = new String[maxRequestLines];\n    int i;\n    for (i=0; i&lt;maxrequestlines ; i++) {\n      inputLines[i] = in.readLine();\n      if (inputLines[i] == null) \/\/ Client closed connection.\n        break;\n      if (inputLines[i].length() == 0) { \/\/ Blank line.\n        if (usingPost(inputLines)) {\n          readPostData(inputLines, i, in);\n          i = i + 2;\n        }\n        break;\n      }\n    }\n    printHeader(out);\n    for (int j=0; j&lt;i; j++) {\n      out.println(inputLines[j]);\n    }\n    printTrailer(out);\n    server.close();\n  }\n\n  \/\/ Send standard HTTP response and top of a standard Web page.\n  \/\/ Use HTTP 1.0 for compatibility with all clients.\n  \n  private void printHeader(PrintWriter out) {\n    out.println\n      (&quot;HTTP\/1.0 200 OKrn&quot; +\n       &quot;Server: &quot; + serverName + &quot;rn&quot; +\n       &quot;Content-Type: text\/htmlrn&quot; +\n       &quot;rn&quot; +\n       &quot;n&quot; +\n       &quot;n&quot; +\n       &quot;n&quot; +\n       &quot;  <title>&quot; + serverName + &quot; Results<\/title>n&quot; +\n       &quot;n&quot; +\n       &quot;n&quot; +\n       &quot;n&quot; +\n       &quot;<h1 ALIGN=\"&quot;CENTER&quot;\">&quot; + serverName +\n         &quot; Results<\/h1>n&quot; +\n       &quot;Here is the request line and request headersn&quot; +\n       &quot;sent by your browser:n&quot; +\n       &quot;<\/pre>\n<pre>&quot;);\n  }\n\n  \/\/ Print bottom of a standard Web page.\n  \n  private void printTrailer(PrintWriter out) {\n    out.println\n      (&quot;<\/pre>\n<p>n&quot; +<br \/>\n       &quot;n&quot; +<br \/>\n       &quot;n&quot;);<br \/>\n  }<\/p>\n<p>  \/\/ Normal Web page requests use GET, so this server can simply<br \/>\n  \/\/ read a line at a time. However, HTML forms can also use<br \/>\n  \/\/ POST, in which case we have to determine the number of POST<br \/>\n  \/\/ bytes that are sent so we know how much extra data to read<br \/>\n  \/\/ after the standard HTTP headers.<\/p>\n<p>  private boolean usingPost(String[] inputs) {<br \/>\n    return(inputs[0].toUpperCase().startsWith(&quot;POST&quot;));<br \/>\n  }<\/p>\n<p>  private void readPostData(String[] inputs, int i,<br \/>\n                            BufferedReader in)<br \/>\n      throws IOException {<br \/>\n    int contentLength = contentLength(inputs);<br \/>\n    char[] postData = new char[contentLength];<br \/>\n    in.read(postData, 0, contentLength);<br \/>\n    inputs[++i] = new String(postData, 0, contentLength);<br \/>\n  }<\/p>\n<p>  \/\/ Given a line that starts with Content-Length,<br \/>\n  \/\/ this returns the integer value specified.<\/p>\n<p>  private int contentLength(String[] inputs) {<br \/>\n    String input;<br \/>\n    for (int i=0; i&lt;inputs .length; i++) {<br \/>\n      if (inputs[i].length() == 0)<br \/>\n        break;<br \/>\n      input = inputs[i].toUpperCase();<br \/>\n      if (input.startsWith(&quot;CONTENT-LENGTH&quot;))<br \/>\n        return(getLength(input));<br \/>\n    }<br \/>\n    return(0);<br \/>\n  }<\/p>\n<p>  private int getLength(String length) {<br \/>\n    StringTokenizer tok = new StringTokenizer(length);<br \/>\n    tok.nextToken();<br \/>\n    return(Integer.parseInt(tok.nextToken()));<br \/>\n  }<br \/>\n}<\/p>\n<p>NetworkServer.java  A starting point for network servers. <\/p>\n<p>import java.net.*;<br \/>\nimport java.io.*;<\/p>\n<p>\/** A starting point for network servers. You&#039;ll need to<br \/>\n *  override handleConnection, but in many cases listen can<br \/>\n *  remain unchanged. NetworkServer uses SocketUtil to simplify<br \/>\n *  the creation of the PrintWriter and BufferedReader.<br \/>\n *<br \/>\n *  Taken from Core Web Programming from<br \/>\n *  Prentice Hall and Sun Microsystems Press,<br \/>\n *  .<br \/>\n *  &copy; 2001 Marty Hall and Larry Brown;<br \/>\n *  may be freely used or adapted.<br \/>\n *\/<\/p>\n<p>public class NetworkServer {<br \/>\n  private int port, maxConnections;<\/p>\n<p>  \/** Build a server on specified port. It will continue to<br \/>\n   *  accept connections, passing each to handleConnection until<br \/>\n   *  an explicit exit command is sent (e.g., System.exit) or<br \/>\n   *  the maximum number of connections is reached. Specify<br \/>\n   *  0 for maxConnections if you want the server to run<br \/>\n   *  indefinitely.<br \/>\n   *\/<\/p>\n<p>  public NetworkServer(int port, int maxConnections) {<br \/>\n    setPort(port);<br \/>\n    setMaxConnections(maxConnections);<br \/>\n  }<\/p>\n<p>  \/** Monitor a port for connections. Each time one is<br \/>\n   *  established, pass resulting Socket to handleConnection.<br \/>\n   *\/<\/p>\n<p>  public void listen() {<br \/>\n    int i=0;<br \/>\n    try {<br \/>\n      ServerSocket listener = new ServerSocket(port);<br \/>\n      Socket server;<br \/>\n      while((i++ &lt; maxConnections) || (maxConnections == 0)) {<br \/>\n        server = listener.accept();<br \/>\n        handleConnection(server);<br \/>\n      }<br \/>\n    } catch (IOException ioe) {<br \/>\n      System.out.println(&quot;IOException: &quot; + ioe);<br \/>\n      ioe.printStackTrace();<br \/>\n    }<br \/>\n  }<\/p>\n<p>  \/** This is the method that provides the behavior to the<br \/>\n   *  server, since it determines what is done with the<br \/>\n   *  resulting socket. <b>Override this method in servers<br \/>\n   *  you write.<br \/>\n   *  <\/p>\n<p>\n   *  This generic version simply reports the host that made<br \/>\n   *  the connection, shows the first line the client sent,<br \/>\n   *  and sends a single line in response.<br \/>\n   *\/<\/p>\n<p>  protected void handleConnection(Socket server)<br \/>\n      throws IOException{<br \/>\n    BufferedReader in = SocketUtil.getReader(server);<br \/>\n    PrintWriter out = SocketUtil.getWriter(server);<br \/>\n    System.out.println<br \/>\n      (&quot;Generic Network Server: got connection from &quot; +<br \/>\n       server.getInetAddress().getHostName() + &quot;n&quot; +<br \/>\n       &quot;with first line &#8216;&quot; + in.readLine() + &quot;&#8217;&quot;);<br \/>\n    out.println(&quot;Generic Network Server&quot;);<br \/>\n    server.close();<br \/>\n  }<\/p>\n<p>  \/** Gets the max connections server will handle before<br \/>\n   *  exiting. A value of 0 indicates that server should run<br \/>\n   *  until explicitly killed.<br \/>\n   *\/<\/p>\n<p>  public int getMaxConnections() {<br \/>\n    return(maxConnections);<br \/>\n  }<\/p>\n<p>  \/** Sets max connections. A value of 0 indicates that server<br \/>\n   *  should run indefinitely (until explicitly killed).<br \/>\n   *\/<\/p>\n<p>  public void setMaxConnections(int maxConnections) {<br \/>\n    this.maxConnections = maxConnections;<br \/>\n  }<\/p>\n<p>  \/** Gets port on which server is listening. *\/<\/p>\n<p>  public int getPort() {<br \/>\n    return(port);<br \/>\n  }<\/p>\n<p>  \/** Sets port. <b>You can only do before &quot;connect&quot; is<br \/>\n   *  called.<\/b> That usually happens in the constructor.<br \/>\n   *\/<\/p>\n<p>  protected void setPort(int port) {<br \/>\n    this.port = port;<br \/>\n  }<br \/>\n}<\/p>\n<p>SocketUtil.java  Simplifies the creation of a PrintWriter and BufferedReader.<\/p>\n<p>import java.net.*;<br \/>\nimport java.io.*;<\/p>\n<p>\/** A shorthand way to create BufferedReaders and<br \/>\n *  PrintWriters associated with a Socket.<br \/>\n *<br \/>\n *  Taken from Core Web Programming from<br \/>\n *  Prentice Hall and Sun Microsystems Press,<br \/>\n *  &copy; 2001 Marty Hall and Larry Brown;<br \/>\n *  may be freely used or adapted.<br \/>\n *\/<\/p>\n<p>public class SocketUtil {<br \/>\n  \/** Make a BufferedReader to get incoming data. *\/<\/p>\n<p>  public static BufferedReader getReader(Socket s)<br \/>\n      throws IOException {<br \/>\n    return(new BufferedReader(<br \/>\n       new InputStreamReader(s.getInputStream())));<br \/>\n  }<\/p>\n<p>  \/** Make a PrintWriter to send outgoing data.<br \/>\n   *  This PrintWriter will automatically flush stream<br \/>\n   *  when println is called.<br \/>\n   *\/<\/p>\n<p>  public static PrintWriter getWriter(Socket s)<br \/>\n      throws IOException {<br \/>\n    \/\/ Second argument of true means autoflush.<br \/>\n    return(new PrintWriter(s.getOutputStream(), true));<br \/>\n  }<br \/>\n}<\/p>\n<p>Note: Brought from our old site: http:\/\/www.salearningschool.com\/example_codes\/ on Jan 2nd, 2017 From: http:\/\/sitestree.com\/?p=10237<br \/> Categories:Programming Code Examples, Java\/J2EE\/J2ME, Network Programming<br \/>Tags:Java\/J2EE\/J2MENetwork Programming<br \/> Post Data:2017-01-02 16:04:28<\/p>\n<p>\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com\/' target='new' rel=\"noopener\">https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\t(Big Data, Cloud, Security, Machine Learning): Courses: <a href='http:\/\/Training.SitesTree.com' target='new' rel=\"noopener\"> http:\/\/Training.SitesTree.com<\/a><br \/>\n\t\tIn Bengali: <a href='http:\/\/Bangla.SaLearningSchool.com' target='new' rel=\"noopener\">http:\/\/Bangla.SaLearningSchool.com<\/a><br \/>\n\t\t<a href='http:\/\/SitesTree.com' target='new' rel=\"noopener\">http:\/\/SitesTree.com<\/a><br \/>\n\t\t8112223 Canada Inc.\/JustEtc: <a href='http:\/\/JustEtc.net' target='new' rel=\"noopener\">http:\/\/JustEtc.net (Software\/Web\/Mobile\/Big-Data\/Machine Learning) <\/a><br \/>\n\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com'> https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\tMedium: <a href='https:\/\/medium.com\/@SayedAhmedCanada' target='new' rel=\"noopener\"> https:\/\/medium.com\/@SayedAhmedCanada <\/a><\/p>\n<p><\/b><\/p>\n","protected":false},"excerpt":{"rendered":"<p>ThreadedEchoServer.java A multithreaded version of EchoServer, where each client request is serviced on a separate thread. Requires the following classes: import java.net.*; import java.io.*; \/** A multithreaded variation of EchoServer. * * Taken from Core Web Programming from * Prentice Hall and Sun Microsystems Press, * . * &copy; 2001 Marty Hall and Larry Brown; &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=26743\">Continue reading<\/a><\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1917],"tags":[],"class_list":["post-26743","post","type-post","status-publish","format-standard","hentry","category-fromsitestree-com","item-wrap"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":10204,"url":"http:\/\/bangla.sitestree.com\/?p=10204","url_meta":{"origin":26743,"position":0},"title":"ThreadedEchoServer.java A multithreaded version of EchoServer, where each client request is serviced on a separate thread. Requires the following classes","author":"","date":"August 25, 2015","format":false,"excerpt":"import java.net.*; import java.io.*; \/** A multithreaded variation of EchoServer. \u00a0* \u00a0*\u00a0 Taken from Core Web Programming from \u00a0*\u00a0 Prentice Hall and Sun Microsystems Press, \u00a0*\u00a0 . \u00a0*\u00a0 \u00a9 2001 Marty Hall and Larry Brown; \u00a0*\u00a0 may be freely used or adapted. \u00a0*\/ public class ThreadedEchoServer extends EchoServer \u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 implements\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10192,"url":"http:\/\/bangla.sitestree.com\/?p=10192","url_meta":{"origin":26743,"position":1},"title":"UrlRetriever.java Accepts an URL from the command line, parses the host, port, and URI components from the URL and then retrieves the document. Requires the following classes","author":"","date":"August 24, 2015","format":false,"excerpt":"UrlRetriever.java\u00a0 Accepts an URL from the command line, parses the host, port, and URI components from the URL and then retrieves the document. Requires the following classes: import java.util.*; \/** This parses the input to get a host, port, and file, then \u00a0*\u00a0 passes these three values to the UriRetriever\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":26591,"url":"http:\/\/bangla.sitestree.com\/?p=26591","url_meta":{"origin":26743,"position":2},"title":"UrlRetriever.java  Accepts an URL from the command line, parses the host, port, and URI components from the URL and then retrieves the document. Requires the following classes: #Programming Code Examples #Java\/J2EE\/J2ME #Network Programming","author":"Author-Check- Article-or-Video","date":"April 29, 2021","format":false,"excerpt":"UrlRetriever.java Accepts an URL from the command line, parses the host, port, and URI components from the URL and then retrieves the document. Requires the following classes: import java.util.*; \/** This parses the input to get a host, port, and file, then * passes these three values to the UriRetriever\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":26489,"url":"http:\/\/bangla.sitestree.com\/?p=26489","url_meta":{"origin":26743,"position":3},"title":"UriRetriever.java  Accepts a host, port, and file from the command line and retrieves the implied URL from the HTTP server by issuing a GET request. Uses the following classes: #Programming Code Examples #NULL #Network Programming","author":"Author-Check- Article-or-Video","date":"April 26, 2021","format":false,"excerpt":"UriRetriever.java Accepts a host, port, and file from the command line and retrieves the implied URL from the HTTP server by issuing a GET request. Uses the following classes: import java.net.*; import java.io.*; \/** Retrieve a URL given the host, port, and file as three * separate command-line arguments. A\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10183,"url":"http:\/\/bangla.sitestree.com\/?p=10183","url_meta":{"origin":26743,"position":4},"title":"NetworkClientTest.java Makes a simple connection to the host and port specified on the command line. Uses the following classes","author":"","date":"August 21, 2015","format":false,"excerpt":"NetworkClientTest.java\u00a0 Makes a simple connection to the host and port specified on the command line. Uses the following classes: \/** Make simple connection to host and port specified. \u00a0* \u00a0*\u00a0 Taken from Core Web Programming from \u00a0*\u00a0 Prentice Hall and Sun Microsystems Press, \u00a0*\u00a0 . \u00a0*\u00a0 \u00a9 2001 Marty Hall\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":26583,"url":"http:\/\/bangla.sitestree.com\/?p=26583","url_meta":{"origin":26743,"position":5},"title":"NetworkClientTest.java  Makes a simple connection to the host and port specified on the command line. Uses the following classes: #Programming Code Examples #Java\/J2EE\/J2ME #Network Programming","author":"Author-Check- Article-or-Video","date":"April 29, 2021","format":false,"excerpt":"NetworkClientTest.java Makes a simple connection to the host and port specified on the command line. Uses the following classes: \/** Make simple connection to host and port specified. * * Taken from Core Web Programming from * Prentice Hall and Sun Microsystems Press, * . * \u00a9 2001 Marty Hall\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/26743","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=26743"}],"version-history":[{"count":0,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/26743\/revisions"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=26743"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=26743"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=26743"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}