MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / bytes

Method bytes

source/base/StarAssets.cpp:594–599  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

592}
593
594ByteArrayConstPtr Assets::bytes(String const& path) const {
595 auto components = AssetPath::split(path);
596 validatePath(components, false, false);
597
598 return as<BytesData>(getAsset(AssetId{AssetType::Bytes, std::move(components)}))->bytes;
599}
600
601IODevicePtr Assets::openFile(String const& path) const {
602 return open(path);

Callers

nothing calls this directly

Calls 1

validatePathFunction · 0.85

Tested by

no test coverage detected