Search in sources :

Example 1 with PerlNamespaceAnnotations

use of com.perl5.lang.perl.psi.utils.PerlNamespaceAnnotations in project Perl5-IDEA by Camelcade.

the class PerlNamespaceDefinitionElementType method serialize.

@Override
public void serialize(@NotNull PerlNamespaceDefinitionStub stub, @NotNull StubOutputStream dataStream) throws IOException {
    dataStream.writeName(stub.getPackageName());
    dataStream.writeName(stub.getMroType().toString());
    PerlStubSerializationUtil.writeStringsList(dataStream, stub.getParentNamespacesNames());
    PerlStubSerializationUtil.writeStringsList(dataStream, stub.getEXPORT());
    PerlStubSerializationUtil.writeStringsList(dataStream, stub.getEXPORT_OK());
    PerlStubSerializationUtil.writeStringListMap(dataStream, stub.getEXPORT_TAGS());
    PerlNamespaceAnnotations namespaceAnnotations = stub.getAnnotations();
    if (namespaceAnnotations == null) {
        dataStream.writeBoolean(false);
    } else {
        dataStream.writeBoolean(true);
        namespaceAnnotations.serialize(dataStream);
    }
}
Also used : PerlNamespaceAnnotations(com.perl5.lang.perl.psi.utils.PerlNamespaceAnnotations)

Aggregations

PerlNamespaceAnnotations (com.perl5.lang.perl.psi.utils.PerlNamespaceAnnotations)1