-
Notifications
You must be signed in to change notification settings - Fork 26
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
Showing
45 changed files
with
1,085 additions
and
180 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
[![wercker status](https://app.wercker.com/status/24c4765f3a0d79520ad80a1e4c20cfa2/s/master "wercker status")](https://app.wercker.com/project/bykey/24c4765f3a0d79520ad80a1e4c20cfa2) [![Coverage Status](https://coveralls.io/repos/logic-ng/LogicNG/badge.svg?branch=master&service=github)](https://coveralls.io/github/logic-ng/LogicNG?branch=master) ![License](https://img.shields.io/badge/license-Apache%202-blue.svg) ![Version](https://img.shields.io/badge/version-1.6.1-ff69b4.svg) | ||
[![wercker status](https://app.wercker.com/status/24c4765f3a0d79520ad80a1e4c20cfa2/s/master "wercker status")](https://app.wercker.com/project/bykey/24c4765f3a0d79520ad80a1e4c20cfa2) [![Coverage Status](https://coveralls.io/repos/logic-ng/LogicNG/badge.svg?branch=master&service=github)](https://coveralls.io/github/logic-ng/LogicNG?branch=master) ![License](https://img.shields.io/badge/license-Apache%202-blue.svg) ![Version](https://img.shields.io/badge/version-1.6.2-ff69b4.svg) | ||
|
||
<img src="https://github.com/logic-ng/LogicNG/blob/master/doc/logo/logo_big.png" alt="logo" width="300"> | ||
|
||
|
@@ -19,7 +19,7 @@ LogicNG is released in the Maven Central Repository. To include it just add | |
<dependency> | ||
<groupId>org.logicng</groupId> | ||
<artifactId>logicng</artifactId> | ||
<version>1.6.1</version> | ||
<version>1.6.2</version> | ||
</dependency> | ||
``` | ||
to your Maven POM. | ||
|
@@ -62,6 +62,11 @@ We recently started a Wiki section for a [FAQ](https://github.com/logic-ng/Logic | |
The library is released under the Apache License and therefore is free to use in any private, educational, or commercial projects. Commercial support is available through the German company [BooleWorks GmbH](http://www.booleworks.com) - the company behind LogicNG. Please contact Christoph Zengler at [email protected] for further details. | ||
|
||
## Changelog | ||
|
||
### Version 1.6.2 (Release January 2020) | ||
* Some improvements to handlers for computations | ||
* New BDD handlers | ||
|
||
### Version 1.6.1 (Release September 2019) | ||
* A new method for solving a formula with a given literal ordering. | ||
* Minor refactoring of the Formatter super class (no effects on callers). | ||
|
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
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
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,43 @@ | ||
/////////////////////////////////////////////////////////////////////////// | ||
// __ _ _ ________ // | ||
// / / ____ ____ _(_)____/ | / / ____/ // | ||
// / / / __ \/ __ `/ / ___/ |/ / / __ // | ||
// / /___/ /_/ / /_/ / / /__/ /| / /_/ / // | ||
// /_____/\____/\__, /_/\___/_/ |_/\____/ // | ||
// /____/ // | ||
// // | ||
// The Next Generation Logic Library // | ||
// // | ||
/////////////////////////////////////////////////////////////////////////// | ||
// // | ||
// Copyright 2015-20xx Christoph Zengler // | ||
// // | ||
// Licensed under the Apache License, Version 2.0 (the "License"); // | ||
// you may not use this file except in compliance with the License. // | ||
// You may obtain a copy of the License at // | ||
// // | ||
// http://www.apache.org/licenses/LICENSE-2.0 // | ||
// // | ||
// Unless required by applicable law or agreed to in writing, software // | ||
// distributed under the License is distributed on an "AS IS" BASIS, // | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or // | ||
// implied. See the License for the specific language governing // | ||
// permissions and limitations under the License. // | ||
// // | ||
/////////////////////////////////////////////////////////////////////////// | ||
|
||
package org.logicng.handlers; | ||
|
||
/** | ||
* Interface for a handler for the BDD factory. | ||
* @version 1.6.2 | ||
* @since 1.6.2 | ||
*/ | ||
public interface BDDHandler extends Handler { | ||
|
||
/** | ||
* This method is called every a new reference is added, i.e the method {@link org.logicng.bdds.jbuddy.BDDKernel#addRef(int, BDDHandler)} is called. | ||
* @return whether BDD generation should be continued or not | ||
*/ | ||
boolean newRefAdded(); | ||
} |
21 changes: 21 additions & 0 deletions
21
src/main/java/org/logicng/handlers/ComputationHandler.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,21 @@ | ||
package org.logicng.handlers; | ||
|
||
/** | ||
* A computation handler. | ||
* @version 1.6.2 | ||
* @since 1.6.2 | ||
*/ | ||
public abstract class ComputationHandler implements Handler { | ||
|
||
protected boolean aborted; | ||
|
||
@Override | ||
public boolean aborted() { | ||
return this.aborted; | ||
} | ||
|
||
@Override | ||
public void started() { | ||
this.aborted = false; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package org.logicng.handlers; | ||
|
||
/** | ||
* Interface for a handler. A handler can be used as callback for different time-intensive computations in order | ||
* to abort these computations. There are same often used default handlers already implemented and users can | ||
* implement their own handlers by implementing the respective interfaces. | ||
* @version 1.6.2 | ||
* @since 1.6.2 | ||
*/ | ||
public interface Handler { | ||
|
||
/** | ||
* Returns whether the computation was aborted by the handler. | ||
* @return {@code true} if the computation was aborted by the handler, otherwise {@code false} | ||
*/ | ||
public boolean aborted(); | ||
|
||
/** | ||
* This method is called when the computation starts. | ||
*/ | ||
public void started(); | ||
} |
Oops, something went wrong.