Re: [Simpleweb-Support] How do I get the complete list of http headers that have a specific name
Brought to you by:
niallg
From: Niall G. <gal...@ya...> - 2014-03-21 09:00:38
|
Hi, Yes this is correct, if the value is null then there are no more to be acquired. There probably should be a count exposed for convenience. However for now you will just have to iterate until you get null. I personally use getValues mostly. Niall -------------------------------------------- On Tue, 18/3/14, Vincent Tencé <vt...@gm...> wrote: Subject: Re: [Simpleweb-Support] How do I get the complete list of http headers that have a specific name To: "Simple support and user issues" <sim...@li...> Received: Tuesday, 18 March, 2014, 8:19 PM Thanks Niall, I missed that. I'm a bit confused when reading the javadoc of the different versions of this method. Here's what I understand: getValue(name) returns the header value for the first header with that namegetValue(name, index) returns the value for the index header with that namegetValues(name) returns the parsed tokens of the all headers with that name Am I correct ? When using the form with the index, how do I know how many headers exist with the same name? Thanks for you help,-- Vincent 2014-03-18 22:33 GMT-04:00 Niall Gallagher <gal...@ya...>: See http://www.simpleframework.org/doc/javadoc/org/simpleframework/http/RequestHeader.html#getValue(java.lang.String, int) -------------------------------------------- On Tue, 18/3/14, Vincent Tencé <vt...@gm...> wrote: Subject: [Simpleweb-Support] How do I get the complete list of http headers that have a specific name To: sim...@li... Received: Tuesday, 18 March, 2014, 3:25 PM Hi guys, I'm trying to get the list of http headers that have a specific name (in this case, I'm looking for all Accept-Encoding headers). The Request#getValues(name) method only return headers that are acceptable. I need the complete list so that I know why ones the client will not accept. How would you do that? Thanks,-- Vincent -----Inline Attachment Follows----- ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/13534_NeoTech -----Inline Attachment Follows----- _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/13534_NeoTech _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support -----Inline Attachment Follows----- ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/13534_NeoTech -----Inline Attachment Follows----- _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support |