Skip to content
This repository has been archived by the owner on Oct 3, 2020. It is now read-only.

Commit

Permalink
working on KeyWord.kt
Browse files Browse the repository at this point in the history
  • Loading branch information
fulton committed Nov 15, 2019
1 parent 6bbbb38 commit 802c984
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 5 additions & 2 deletions src/main/java/com/andromeda/araserver/Run.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,18 @@
import com.andromeda.araserver.skills.*;
import com.andromeda.araserver.pages.ApiStart;
import com.andromeda.araserver.store.Main;
import com.andromeda.araserver.util.KeyWord;
import com.rometools.rome.feed.synd.SyndFeed;
import com.rometools.rome.io.FeedException;
import com.rometools.rome.io.SyndFeedOutput;
import fi.iki.elonen.NanoHTTPD;

import java.io.IOException;
import java.net.MalformedURLException;
import java.sql.SQLException;


public class Run extends NanoHTTPD {
KeyWord keyWord;


//Function to declare port
Expand All @@ -37,6 +38,7 @@ private Run(int port) throws IOException {
"\n" +
" You should have received a copy of the GNU General Public License\n" +
" along with this program. If not, see <https://www.gnu.org/licenses/>.");
//keyWord = new KeyWord()
}


Expand All @@ -45,7 +47,7 @@ public static void main(String[] args) {
// If this is in a heroku environment, get the port number
String webPort = System.getenv("PORT");
if (webPort == null || webPort.isEmpty()) {
// If not set to 80
// If not set to 8080
webPort = "8080";
}
//Get port value and start server
Expand All @@ -56,6 +58,7 @@ public static void main(String[] args) {
}
}


@Override
//If connected to
public NanoHTTPD.Response serve(NanoHTTPD.IHTTPSession session) {
Expand Down
5 changes: 2 additions & 3 deletions src/main/java/com/andromeda/araserver/util/KeyWord.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ import opennlp.tools.parser.ParserModel
import java.io.InputStream


class KeyWord(text:String, is1:InputStream ) {
private val mainVal = text
class KeyWord(is1:InputStream ) {
private val mainIs = is1
fun getKeyWords(): Array<out Parse>? {
fun getKeyWords(mainVal:String): Array<out Parse>? {
val m =ParserModel(mainIs)
val parser = ParserFactory.create(m)

Expand Down

0 comments on commit 802c984

Please sign in to comment.