Return-Path: Delivered-To: apmail-commons-user-archive@www.apache.org Received: (qmail 56474 invoked from network); 2 Sep 2008 18:48:31 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Sep 2008 18:48:31 -0000 Received: (qmail 61334 invoked by uid 500); 2 Sep 2008 18:48:25 -0000 Delivered-To: apmail-commons-user-archive@commons.apache.org Received: (qmail 61273 invoked by uid 500); 2 Sep 2008 18:48:25 -0000 Mailing-List: contact user-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Users List" Delivered-To: mailing list user@commons.apache.org Received: (qmail 61262 invoked by uid 99); 2 Sep 2008 18:48:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 02 Sep 2008 11:48:25 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of ted.dunning@gmail.com designates 64.233.166.180 as permitted sender) Received: from [64.233.166.180] (HELO py-out-1112.google.com) (64.233.166.180) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 02 Sep 2008 18:47:27 +0000 Received: by py-out-1112.google.com with SMTP id f47so1357841pye.6 for ; Tue, 02 Sep 2008 11:47:41 -0700 (PDT) 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:references; bh=Rnn+9RNBlVkuXcxld+FdgQf2FrMWW8gLdbYyi7uB9y0=; b=Pjyg7FprnSIX5kj3hnxY/8RTV9lZtPYvGu4JdeLtqdsaFv5Le+t4duDIjfbwHzsHJM fVXJ6I/oyrEB5iXb/xhM8qq1mzj+ZPODJg5HCsuhLZAOqgB5B7vrcGW7ejHC9wvsyOR5 2UjD03BqGO0oR1WesiMLHwvWvzg0pqpWVQQeE= 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:references; b=TMuet0E9r+pZXCNpCDT6kEEfw81iGTeZnpO4awvrsS2TOlysJLeq+TmuFF/24mS4GN weHoLlOg0LdPVYydzJVJ2SF6SzFZ24WsdTUlC/Q/tihP+FOzTKSs2m+Lc5+LjMzEq/yT EgB9N40cL70LNngh7ZcbzAIkh8/Bgi+n45ApA= Received: by 10.114.89.1 with SMTP id m1mr6720093wab.146.1220381260025; Tue, 02 Sep 2008 11:47:40 -0700 (PDT) Received: by 10.115.55.16 with HTTP; Tue, 2 Sep 2008 11:47:39 -0700 (PDT) Message-ID: Date: Tue, 2 Sep 2008 11:47:39 -0700 From: "Ted Dunning" To: "Commons Users List" Subject: Re: isEscaped In-Reply-To: <1195336e0809021128s6500f488q5c8b763f8fdc33c5@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_5882_31282178.1220381260006" References: <1195336e0809021128s6500f488q5c8b763f8fdc33c5@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_5882_31282178.1220381260006 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline Isn't this a pretty simple regex? Just look for <'s and &'s without entity syntax. On Tue, Sep 2, 2008 at 11:28 AM, Gabriel Reis wrote: > Hi, > > Is there any tool to verify if a String is escaped? Something like this: > > assertFalse( StringEscapeUtils.isHtmlEscaped("text") ); > > assertTrue( StringEscapeUtils.isHtmlEscaped("<b>text</b>") ); > > > []s > Gabriel > -- ted ------=_Part_5882_31282178.1220381260006--