Lines Matching +full:if +full:- +full:no +full:- +full:files +full:- +full:found
1 // SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
11 "github.com/spdx/tools-golang/spdx/common"
12 "github.com/spdx/tools-golang/spdx/v2_3"
24 Files: []*v2_3.File{},
30 files: map[common.ElementID]*v2_3.File{},
47 if err != nil {
52 if err != nil {
59 if len(typeTriples) != 1 {
60 …return nil, fmt.Errorf("every node must be associated with exactly 1 type Triple. found %d type tr…
67 if err != nil {
71 if err != nil {
82 // parsing packages and files sets the files to a files variable which is
84 // necessary to transfer the files which are not set in the packages to the
85 // Files attribute of the document
92 // returns error if the document is associated with no SpdxDocument or
113 if typeTriples[0].Object.ID == SPDX_SPDX_DOCUMENT_CAPITALIZED {
114 // we found a SpdxDocument Node
117 if len(typeTriples) != 1 {
119 " triple of predicate rdf:type, found %d triples", rootNode, len(typeTriples))
122 // checking if we've already found a node and it is not same as the current one.
123 if spdxDocNode != nil && spdxDocNode.ID != typeTriples[0].Subject.ID {
124 …return nil, fmt.Errorf("found more than one SpdxDocument Node (%v and %v)", spdxDocNode, typeTripl…
129 if spdxDocNode == nil {
130 return nil, errors.New("RDF files must be associated with a SpdxDocument tag. No tag found")