private void buildParentFilterDocument(StringBuilder buffer) {
		buffer.append("\"filter\": { ");
		buffer.append("\"has_parent\": { ");
		buffer.append("\"parent_type\": \"exe\", ");
		buffer.append("\"query\": { ");
		buffer.append("\"bool\": { ");
		boolean needsComma = false;
		if (!standaloneFilter.isEmpty()) {
			buildStandaloneFilters(buffer);
			needsComma = true;
		}
		if (!booleanElements.isEmpty()) {
			if (needsComma) {
				buffer.append(',');
			}
			buffer.append("\"filter\": { ");
			buffer.append("\"script\": { \"script\": { ");
			buildParentScript(buffer);
			buffer.append("} } }");
		}
		buffer.append("} } } }");
	}
Container for collecting an elasticsearch query filter document from BSimFilter elements
Ghidra/Features/BSim/src/main/java/ghidra/features/bsim/query/elastic/ElasticEffects.java