Return-Path: Delivered-To: apmail-struts-user-archive@www.apache.org Received: (qmail 37572 invoked from network); 8 Jan 2009 16:24:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 Jan 2009 16:24:30 -0000 Received: (qmail 59460 invoked by uid 500); 8 Jan 2009 16:24:21 -0000 Delivered-To: apmail-struts-user-archive@struts.apache.org Received: (qmail 59432 invoked by uid 500); 8 Jan 2009 16:24:21 -0000 Mailing-List: contact user-help@struts.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Struts Users Mailing List" Reply-To: "Struts Users Mailing List" Delivered-To: mailing list user@struts.apache.org Received: (qmail 59420 invoked by uid 99); 8 Jan 2009 16:24:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Jan 2009 08:24:21 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of musachy@gmail.com designates 209.85.146.181 as permitted sender) Received: from [209.85.146.181] (HELO wa-out-1112.google.com) (209.85.146.181) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Jan 2009 16:24:12 +0000 Received: by wa-out-1112.google.com with SMTP id l24so5082873waf.11 for ; Thu, 08 Jan 2009 08:23:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=2IVRAH7glAm4BJ/OJgOnyyw9H1pea7UQ0bCZEkALL38=; b=gWvWnpIHZhDke7TPdyFQrreiZkoU0cPPkeFueVWFc3C1zsG3ZdrpJ4c8oQz+EX6Hu3 +lKpJU8JTVER53agmHWZ3iFCPEqI3+xwPVOEje/JSHCpXSTAsCjQAHGOFlayb3U06j5q BmUtNB4BC0H0K8zxOqB2/B9XBGMJ5QdXh3Wr4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=cRwl5LzR2GG2dB2/2R5dumGDILridZqaBIvesRjUAvMW+pURcZk21HNTX6BlNr69NJ vDbIs3wxmUalwEeBSoTsAZ42q3zvnEaCM8ZOMdgcO5w4t8xpIRqN54vdj+c46KsVRirU kPIVrFD7t3C6oFthmDgCrbwAADu4npSjYsm6g= Received: by 10.115.108.1 with SMTP id k1mr16182374wam.0.1231431832464; Thu, 08 Jan 2009 08:23:52 -0800 (PST) Received: by 10.115.77.13 with HTTP; Thu, 8 Jan 2009 08:23:52 -0800 (PST) Message-ID: Date: Thu, 8 Jan 2009 11:23:52 -0500 From: "Musachy Barroso" To: "Struts Users Mailing List" Subject: Re: REST Again In-Reply-To: <3a71add70901080813k2241a95bu79f487a3b44a0353@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <3a71add70901080813k2241a95bu79f487a3b44a0353@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org ok, here we go. Looking at the rest showcase application, when you hit this url: /orders/10 the REST plugin (to simplify) says "I have to invoke the 'show' method in the 'orders' action, and set its 'id' parameter to 10". How does the REST plugin know what to invoke? based on some simple convention rules which are defined in the documentation: * GET: /movies => method="index" * GET: /movies/Thrillers => method="show", id="Thrillers" * GET: /movies/Thrillers;edit => method="edit", id="Thrillers" * GET: /movies/Thrillers/edit => method="edit", id="Thrillers" * GET: /movies/new => method="editNew" * POST: /movies => method="create" * PUT: /movies/Thrillers => method="update", id="Thrillers" * DELETE: /movies/Thrillers => method="destroy", id="Thrillers" so, the REST plugin based on some conventions, saves you the time of having to define the mappings for the actions and results, among other things. musachy On Thu, Jan 8, 2009 at 11:13 AM, Frans Thamura wrote: > hi there > > chat with musa > > and he said that REST create the "action" for us > > but i still dont get, > > first Struts without REST, 1 action 1 result > > in REST, 1 result multiple action and mapped as REST URL > > can help all > -- > -- > Frans Thamura > Meruvian > One Stop Java and Enterprise OSS Provider > Technopreneurship, Training, Internship, Outsourcing and Corporate > Competency Center > > Mobile: +62 855 7888 699 > Blog & Profile: http://frans.thamura.info > > Training JENI, Medallion (Alfresco, Liferay dan Compiere).. buruan... > URL: http://www.meruvian.com > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > For additional commands, e-mail: user-help@struts.apache.org > > -- "Hey you! Would you help me to carry the stone?" Pink Floyd --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@struts.apache.org For additional commands, e-mail: user-help@struts.apache.org