-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3512922
commit d5f2f51
Showing
4 changed files
with
72 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
src/main/java/org/eclipse/dash/licenses/spdx/SpdxPlus.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/************************************************************************* | ||
* Copyright (c) 2020 The Eclipse Foundation and others. | ||
* | ||
* This program and the accompanying materials are made available under | ||
* the terms of the Eclipse Public License 2.0 which accompanies this | ||
* distribution, and is available at https://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*************************************************************************/ | ||
package org.eclipse.dash.licenses.spdx; | ||
|
||
import java.util.Collection; | ||
|
||
public class SpdxPlus extends SpdxExpression { | ||
private SpdxIdentifier identifier; | ||
|
||
public SpdxPlus(SpdxIdentifier identifier) { | ||
this.identifier = identifier; | ||
} | ||
|
||
@Override | ||
public boolean matchesApproved(Collection<String> approved) { | ||
// TODO Implement this | ||
// We need some means of identifying one license as being a later version of | ||
// another. | ||
return identifier.matchesApproved(approved); | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "(" + identifier.toString() + ")+"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters