summaryrefslogtreecommitdiff
path: root/README.md
blob: 04eff4b0254a4bea32153bfdf2a38a4d890e0e85 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# bgp-java
BGP 4 Connector that can be used for network analysis.

## Usage
```java
BGPServer server = new BGPServer();
server.getSessionConfigurations().add(new BGPSessionConfiguration(
        "demosession",
        1234,
        ip("1.2.3.4"),
        4321,
        ip("4.3.2.1"),
        new BGPListener() {
            public void onOpen(BGPSession session) {
                // DO WHAT YOU WANT
            }
            public void onUpdate(BGPSession session, BGPUpdate update) {
                // DO WHAT YOU WANT
            }
            public void onClose(BGPSession session) {
                // NOT YET IMPLEMENTED
            }
        }
));
server.run();
```

## Maven
```xml
<repository>
    <id>lumaserv</id>
    <url>https://maven.lumaserv.cloud</url>
</repository>
```
```xml
<dependency>
    <groupId>com.lumaserv</groupId>
    <artifactId>bgp-java</artifactId>
    <version>1.0-SNAPSHOT</version>
</dependency>
```