Source Code Cross Referenced for EnglishInflector.java in  » Web-Services-apache-cxf-2.0.1 » bindings » org » apache » cxf » binding » http » strategy » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Services apache cxf 2.0.1 » bindings » org.apache.cxf.binding.http.strategy 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /**
002:         * Licensed to the Apache Software Foundation (ASF) under one
003:         * or more contributor license agreements. See the NOTICE file
004:         * distributed with this work for additional information
005:         * regarding copyright ownership. The ASF licenses this file
006:         * to you under the Apache License, Version 2.0 (the
007:         * "License"); you may not use this file except in compliance
008:         * with the License. You may obtain a copy of the License at
009:         *
010:         * http://www.apache.org/licenses/LICENSE-2.0
011:         *
012:         * Unless required by applicable law or agreed to in writing,
013:         * software distributed under the License is distributed on an
014:         * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
015:         * KIND, either express or implied. See the License for the
016:         * specific language governing permissions and limitations
017:         * under the License.
018:         */
019:        /**
020:         * Copyright (c) 2005-2006 David Heinemeier Hansson
021:         * 
022:         * Permission is hereby granted, free of charge, to any person obtaining
023:         * a copy of this software and associated documentation files (the
024:         * "Software"), to deal in the Software without restriction, including
025:         * without limitation the rights to use, copy, modify, merge, publish,
026:         * distribute, sublicense, and/or sell copies of the Software, and to
027:         * permit persons to whom the Software is furnished to do so, subject to
028:         * the following conditions:
029:
030:         * The above copyright notice and this permission notice shall be
031:         * included in all copies or substantial portions of the Software.
032:
033:         * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
034:         * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
035:         * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
036:         * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
037:         * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
038:         * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
039:         * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
040:         */package org.apache.cxf.binding.http.strategy;
041:
042:        /**
043:         * Rules for English inflection.
044:         * <p>
045:         * Notice: Some portions of this class where ported from Ruby's ActiveSupport
046:         * library which are Copyright (c) 2005-2006 David Heinemeier Hansson and
047:         * under the MIT license.
048:         */
049:        public class EnglishInflector extends Inflector {
050:
051:            public EnglishInflector() {
052:                addPlural("$", "s");
053:                addPlural("s$", "$1s");
054:                addPlural("(ax|test)is$", "$1es");
055:                addPlural("(octop|vir)us$", "$1i");
056:                addPlural("(alias|status)$", "$1es");
057:                addPlural("(bu)s$", "$1ses");
058:                addPlural("(buffal|tomat)o$", "$1oes");
059:                addPlural("([ti])um$", "$1a");
060:                addPlural("sis$", "ses");
061:                addPlural("(?:([^f])fe|([lr])f)$", "$1\2ves");
062:                addPlural("(hive)$", "$1s");
063:                addPlural("([^aeiouy]|qu)y$", "$1ies");
064:                addPlural("(x|ch|ss|sh)$", "$1es");
065:                addPlural("(matr|vert|ind)ix|ex$", "$1ices");
066:                addPlural("([m|l])ouse$", "$1ice");
067:                addPlural("^(ox)$", "$1en");
068:                addPlural("(quiz)$", "$1zes");
069:
070:                addSingular("s$", "");
071:                addSingular("(n)ews$", "$1ews");
072:                addSingular("([ti])a$", "$1um");
073:                addSingular(
074:                        "((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$",
075:                        "$1\2sis");
076:                addSingular("(^analy)ses$", "$1sis");
077:                addSingular("([^f])ves$", "$1fe");
078:                addSingular("(hive)s$", "$1");
079:                addSingular("(tive)s$", "$1");
080:                addSingular("([lr])ves$", "$1f");
081:                addSingular("([^aeiouy]|qu)ies$", "$1y");
082:                addSingular("(s)eries$", "$1eries");
083:                addSingular("(m)ovies$", "$1ovie");
084:                addSingular("(x|ch|ss|sh)es$", "$1");
085:                addSingular("([m|l])ice$", "$1ouse");
086:                addSingular("(bus)es$", "$1");
087:                addSingular("(o)es$", "$1");
088:                addSingular("(shoe)s$", "$1");
089:                addSingular("(cris|ax|test)es$", "$1is");
090:                addSingular("(octop|vir)i$", "$1us");
091:                addSingular("(alias|status)es$", "$1");
092:                addSingular("^(ox)en", "$1");
093:                addSingular("(vert|ind)ices$", "$1ex");
094:                addSingular("(matr)ices$", "$1ix");
095:                addSingular("(quiz)zes$", "$1");
096:
097:                addIrregular("person", "people");
098:                addIrregular("man", "men");
099:                addIrregular("child", "children");
100:                addIrregular("sex", "sexes");
101:                addIrregular("move", "moves");
102:
103:                addUncountable(new String[] { "equipment", "information",
104:                        "rice", "money", "species", "series", "fish", "sheep" });
105:            }
106:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.