MCPcopy Create free account
hub / github.com/FongMi/TV / getContentType

Method getContentType

quickjs/src/main/java/com/fongmi/quickjs/bean/Res.java:52–57  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

50 }
51
52 public String getContentType() {
53 Map<String, String> header = getHeader();
54 List<String> keys = Arrays.asList("Content-Type", "content-type");
55 for (String key : keys) if (header.containsKey(key)) return Objects.requireNonNull(header.get(key));
56 return "application/octet-stream";
57 }
58
59 public ByteArrayInputStream getStream() {
60 if (getBuffer() == 2) return new ByteArrayInputStream(Util.decode(getContent()));

Callers 1

proxy2Method · 0.95

Calls 2

getHeaderMethod · 0.95
getMethod · 0.45

Tested by

no test coverage detected