Esempio n. 1
0
	public String toURIQuery()
	{
		StringBuilder sb = new StringBuilder();
		sb.append("https=");
		sb.append(https);
		sb.append("&saml=");
		sb.append(saml);
		sb.append("&refs=");
		sb.append(refs);
		sb.append("&no_default_t=");
		sb.append(noDefaultT);
		sb.append("&no_default_p=");
		sb.append(noDefaultP);
		sb.append("&no_default_m=");
		sb.append(noDefaultM);
		sb.append("&uric=");
		sb.append(uric);
		sb.append("&cid=");
		sb.append(cid);

		return sb.toString();		
	}
Esempio n. 2
0
	public String getTrustParameters() {
		StringBuilder sb = new StringBuilder();
		sb.append(MimeType.PARAM_HTTPS);
		sb.append("=");
		sb.append(isHttps()? "true" : "false");
		sb.append(";");
		sb.append(MimeType.PARAM_SAML);
		sb.append("=");
		sb.append(isSaml()? "true" : "false");
		return sb.toString();
	}
Esempio n. 3
0
	public String toString()
	{
		StringBuilder sb = new StringBuilder();
		sb.append("ResolverFlags (");
		sb.append(toURIQuery());
		sb.append(")");

		return sb.toString();
	}
Esempio n. 4
0
	private void mHereDocContents()
	{
		EnterRule_HereDocContents();
		EnterRule("HereDocContents", 121);
		TraceIn("HereDocContents", 121);
		try
		{
			// Php.g:736:2: ()
			DebugEnterAlt(1);
			// Php.g:736:4: 
			{
			DebugLocation(736, 4);
			if (state.backtracking == 0)
			{

						// Please see also Code2Xml.Languages.ANTLRv3.Core.ExtensionForParser
						var sb = new StringBuilder();
						while (input.LA(1) != '\n') {
							sb.append((char)input.LA(1));
							input.consume();
						}
						input.consume();
						var hereDocName = sb.toString().TrimEnd();
						var hdnl = hereDocName.length();
						while (true) {
							var matchEnd = true;
							for (int i = 0; i < hdnl; i++) {
								if (input.LA(1) != hereDocName.charAt(i)) {
									matchEnd = false;
									break;
								}
								input.consume();
							}
							if (matchEnd == false) {
								while (input.LA(1) != '\n') {
									input.consume();
								}
								input.consume();
							} else {
								break;
							}
						}
					
			}

			}

		}
		finally
		{
			TraceOut("HereDocContents", 121);
			LeaveRule("HereDocContents", 121);
			LeaveRule_HereDocContents();
		}
	}
 private Document CreateDocument(int n, string indexName,
     int numFields, string format)
 {
     StringBuilder sb = new StringBuilder();
     Document doc = new Document();
     string id = string.Format(CultureInfo.InvariantCulture, format, n);
     doc.Add(NewStringField("id", id, Field.Store.YES));
     doc.Add(NewStringField("indexname", indexName, Field.Store.YES));
     sb.append("a");
     sb.append(n);
     doc.Add(NewTextField("field1", sb.toString(), Field.Store.YES));
     sb.append(" b");
     sb.append(n);
     for (int i = 1; i < numFields; i++)
     {
         doc.Add(NewTextField("field" + (i + 1), sb.toString(), Field.Store.YES));
     }
     return doc;
 }
 public virtual void testRandomQueries2()
 {
     char[] chars = new char[] { 'a', '1', '|', '&', ' ', '(', ')', '"', '-', '~' };
     StringBuilder sb = new StringBuilder();
     for (int i = 0; i < 1000; i++)
     {
         sb.Length = (0);
         int queryLength = Random().Next(20);
         for (int j = 0; j < queryLength; j++)
         {
             sb.append(chars[Random().Next(chars.Length)]);
         }
         Parse(sb.toString()); // no exception
         ParseKeyword(sb.toString(), TestUtil.NextInt(Random(), 0, 1024)); // no exception
     }
 }
Esempio n. 7
0
		public String toString()
		{
			StringBuilder sb = new StringBuilder();
			sb.append("QXRI=");
			sb.append(qxri);
			sb.append(", trust=");
			sb.append(trust);
			sb.append(", uri=");
			sb.append((uri == null)? "null" : uri.toASCIIString());
			sb.append(", ref=");
			sb.append(ref);
			sb.append(", elapsed=");
			sb.append(timeCompleted - timeStarted);
			sb.append("ms\n\nXRDS = \n");
			sb.append(xrds);
			return sb.toString();
		}
Esempio n. 8
0
	public String toString()
	{
		StringBuilder sb = new StringBuilder();
		
		sb.append("NumRequests=" + numRequests + ", numRefsFollowed=" + numRefsFollowed + ", numBytesReceived=" + numBytesReceived + "\n");
		for (int i = 0; i < getNumSteps(); i++) {
			ResolverStep step = getStepAt(i);
			sb.append(step.toString());
			sb.append("\n");
		}
		return sb.toString();
	}