public boolean needsNL()

in src/main/java/com/atlassian/uwc/converters/xml/BasicParser.java [78:106]


		public boolean needsNL(boolean start) {
			if (!typestack.isEmpty()) {
				//check to see if we should be swallowing newlines
				Stack<Type> tmp = new Stack<Type>();
				tmp.addAll(typestack);
				while (!tmp.isEmpty()) {
					Type popped = tmp.pop();
					switch(popped) {
						case BOLD:
						case ITAL:
						case UNDERLINE:
						case STRIKE: {
							//suppressing nl for now. Let's add it later
							addNL = true;
							return false;
						}
					}
				}
			}
			switch (this) {
				case QUOTE: return true;
				case BREAK: return !start; //only want to return true with endElement
			}
			if (typestack.isEmpty() && !start && addNL) {
				addNL = false;
				return true;
			}
			return false;
		}