Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id B155B200D50 for ; Mon, 4 Dec 2017 13:39:08 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id AFB7B160BF9; Mon, 4 Dec 2017 12:39:08 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 01CF7160C05 for ; Mon, 4 Dec 2017 13:39:07 +0100 (CET) Received: (qmail 15420 invoked by uid 500); 4 Dec 2017 12:39:07 -0000 Mailing-List: contact issues-help@struts.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@struts.apache.org Delivered-To: mailing list issues@struts.apache.org Received: (qmail 15406 invoked by uid 99); 4 Dec 2017 12:39:07 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Dec 2017 12:39:07 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 2DF08180701 for ; Mon, 4 Dec 2017 12:39:06 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -100.002 X-Spam-Level: X-Spam-Status: No, score=-100.002 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id XdoeF2bUhiWl for ; Mon, 4 Dec 2017 12:39:05 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id C54705FB87 for ; Mon, 4 Dec 2017 12:39:04 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 67DFEE25CB for ; Mon, 4 Dec 2017 12:39:02 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 4C027255DC for ; Mon, 4 Dec 2017 12:39:01 +0000 (UTC) Date: Mon, 4 Dec 2017 12:39:01 +0000 (UTC) From: "ASF subversion and git services (JIRA)" To: issues@struts.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (WW-4034) Allow to use custom JSONwriter MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 04 Dec 2017 12:39:08 -0000 [ https://issues.apache.org/jira/browse/WW-4034?page=3Dcom.atlassian.ji= ra.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1627672= 3#comment-16276723 ]=20 ASF subversion and git services commented on WW-4034: ----------------------------------------------------- Commit 606fa483bc41fbcbbf90615c5660ee776d587fac in struts-site's branch ref= s/heads/master from [~lukaszlenart] [ https://gitbox.apache.org/repos/asf?p=3Dstruts-site.git;h=3D606fa48 ] Merge pull request #47 from yasserzamani/WW-4034 WW-4034 Adds example for how customizing JSONWriter > Allow to use custom JSONwriter > ------------------------------ > > Key: WW-4034 > URL: https://issues.apache.org/jira/browse/WW-4034 > Project: Struts 2 > Issue Type: Improvement > Components: Plugin - JSON > Reporter: Emir Bu=C4=9Fra K=C3=96KSALAN > Priority: Minor > Labels: JSON > Fix For: 2.5.14 > > > Throws when accessing to a private inner class in that method: > private void map(Map map, Method method) throws JSONException > May be pass when trying to access a private class. example source code sh= ould be: > {code:java} > private void map(Map map, Method method) throws JSONException { > this.add("{"); > ... > while (it.hasNext()) { > Map.Entry entry =3D (Map.Entry) it.next(); > Object key =3D entry.getKey(); > String expr =3D null; > if (this.buildExpr) { > try { > if (key =3D=3D null) { > LOG.error("Cannot build expression for null key in " = + this.exprStack); > continue; > } else { > expr =3D this.expandExpr(key.toString()); > if (this.shouldExcludeProperty(expr)) { > continue; > } > expr =3D this.setExprStack(expr); > } > } > catch (Exception ex) { > LOG.error("Error: " + ex.getLocalizedMessage()); > continue; > } > } > if (hasData) { > this.add(','); > } > ... > this.add("}"); > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)