Skip to content

Commit

Permalink
CleanUp namespaces (#27)
Browse files Browse the repository at this point in the history
* Cleaned up namespaces
  • Loading branch information
jaddek authored Sep 25, 2024
1 parent 0b49c38 commit 7a660fa
Show file tree
Hide file tree
Showing 5 changed files with 101 additions and 5 deletions.
96 changes: 96 additions & 0 deletions index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
import {ResponseDataDecorator} from "./src/ResponseDataDecorator";
import MetlinkHttpClient from "./src/MetlinkHttpClient";
import {MetlinkHttpClientBuilder} from "./src/MetlinkHttpClientBuilder";
import {QueryBuilder} from "./src/QueryBuilder";
import {MetlinkHttpClientInterface, HostInterface} from "./src/Contracts";
import {HeadersBuilder} from "./src/HeadersBuilder";
import {HeadersDirector} from "./src/HeadersDirector";
import {Trip as GtfsTrip} from "./src/domain/gtfs/entity/Trip";
import {Calendar as GtfsCalendar} from "./src/domain/gtfs/entity/Calendar";
import {CalendarDate as GtfsCalendarDate} from "./src/domain/gtfs/entity/CalendarDate";
import {Feed as GtfsFeed} from "./src/domain/gtfs/entity/Feed";
import {Route as GtfsRoute} from "./src/domain/gtfs/entity/Route";
import {ServiceWeeklySchedule as GtfsServiceWeeklySchedule} from "./src/domain/gtfs/entity/ServiceWeeklySchedule";
import {Shape as GtfsServiceShape} from "./src/domain/gtfs/entity/Shape";
import {Stop as GtfsStop} from "./src/domain/gtfs/entity/Stop";
import {StopTime as GtfsStopTime} from "./src/domain/gtfs/entity/StopTime";
import {Transfer as GtfsTransfer} from "./src/domain/gtfs/entity/Transfer";
import {Agency as GtfsAgency} from "./src/domain/gtfs/entity/Agency";
import {AxiosAdapter} from "./src/domain/httpclient/AxiosAdapter";
import {Query as TripCancellationQuery} from "./src/domain/trip-cancellation/Query"
import {Trip as TripCancellationTrip} from "./src/domain/trip-cancellation/Trip"
import {Arrival as StopDeparturePredictionArrival} from "./src/domain/stop-departure-prediction/Arrival";
import {Departure as StopDeparturePredictionDeparture} from "./src/domain/stop-departure-prediction/Departure";
import {Destination as StopDeparturePredictionDestination} from "./src/domain/stop-departure-prediction/Destination";
import {Entity as StopDeparturePredictionEntity} from "./src/domain/stop-departure-prediction/Entity";
import {Origin as StopDeparturePredictionOrigin} from "./src/domain/stop-departure-prediction/Origin";
import {Response as StopDeparturePredictionResponse} from "./src/domain/stop-departure-prediction/Response";
import {Header as GtfsRtHeader} from "./src/domain/gtfs-rt/entity/Header";
import {Response as GtfsRtResponse} from "./src/domain/gtfs-rt/entity/Response";
import {Entity as GtfsRtVehiclePositionsEntity} from "./src/domain/gtfs-rt/entity/vehicle-positions/Entity";
import {Position as GtfsRtVehiclePositionsPosition} from "./src/domain/gtfs-rt/entity/vehicle-positions/Position";
import {Trip as GtfsRtVehiclePositionsTrip} from "./src/domain/gtfs-rt/entity/vehicle-positions/Trip";
import {Vehicle as GtfsRtVehiclePositionsVehicle} from "./src/domain/gtfs-rt/entity/vehicle-positions/Vehicle";
import {VehicleId as GtfsRtVehiclePositionsVehicleId} from "./src/domain/gtfs-rt/entity/vehicle-positions/VehicleId";
import {Arrival as GtfsRtTripUpdateArrival} from "./src/domain/gtfs-rt/entity/trip-update/Arrival";
import {Entity as GtfsRtTripUpdateEntity} from "./src/domain/gtfs-rt/entity/trip-update/Entity";
import {StopTimeUpdate as GtfsRtTripUpdateStopTimeUpdate} from "./src/domain/gtfs-rt/entity/trip-update/StopTimeUpdate";
import {Trip as GtfsRtTripUpdateTrip} from "./src/domain/gtfs-rt/entity/trip-update/Trip";
import {TripUpdate as GtfsRtTripUpdateTripUpdate} from "./src/domain/gtfs-rt/entity/trip-update/TripUpdate";
import {VehicleId as GtfsRtTripUpdateVehicleId} from "./src/domain/gtfs-rt/entity/trip-update/VehicleId";
import {ActivePeriod as GtfsRtServiceAlertActivePeriod} from "./src/domain/gtfs-rt/entity/service-alert/ActivePeriod";
import {Alert as GtfsRtServiceAlertAlert} from "./src/domain/gtfs-rt/entity/service-alert/Alert";
import {Entity as GtfsRtServiceAlertEntity} from "./src/domain/gtfs-rt/entity/service-alert/Entity";
import {InformedEntity as GtfsRtServiceAlertInformedEntity} from "./src/domain/gtfs-rt/entity/service-alert/InformedEntity";
import {Trip as GtfsRtServiceAlertTrip} from "./src/domain/gtfs-rt/entity/service-alert/Trip";



export {
GtfsRtTripUpdateArrival,
GtfsRtTripUpdateEntity,
GtfsRtTripUpdateStopTimeUpdate,
GtfsRtTripUpdateTrip,
GtfsRtTripUpdateTripUpdate,
GtfsRtTripUpdateVehicleId,
GtfsRtServiceAlertActivePeriod,
GtfsRtServiceAlertAlert,
GtfsRtServiceAlertEntity,
GtfsRtServiceAlertInformedEntity,
GtfsRtServiceAlertTrip,
StopDeparturePredictionArrival,
StopDeparturePredictionDeparture,
StopDeparturePredictionDestination,
StopDeparturePredictionEntity,
StopDeparturePredictionOrigin,
StopDeparturePredictionResponse,
GtfsRtHeader,
GtfsRtResponse,
GtfsRtVehiclePositionsEntity,
GtfsRtVehiclePositionsTrip,
GtfsRtVehiclePositionsPosition,
GtfsRtVehiclePositionsVehicle,
GtfsRtVehiclePositionsVehicleId,
GtfsAgency,
GtfsTrip,
GtfsCalendar,
GtfsCalendarDate,
GtfsFeed,
GtfsRoute,
GtfsServiceWeeklySchedule,
GtfsServiceShape,
GtfsStop,
GtfsStopTime,
GtfsTransfer,
TripCancellationQuery,
ResponseDataDecorator,
MetlinkHttpClient,
MetlinkHttpClientBuilder,
QueryBuilder,
MetlinkHttpClientInterface,
HostInterface,
HeadersBuilder,
HeadersDirector,
AxiosAdapter,
TripCancellationTrip,
}
4 changes: 2 additions & 2 deletions src/ResponseDataDecorator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ import { Trip as GtfsTrip } from './domain/gtfs/entity/Trip'
import { Response as GtfsRtResponse } from './domain/gtfs-rt/entity/Response'
import { Trip as ServiceAlertTrip } from './domain/gtfs-rt/entity/service-alert/Trip'
import { Trip as CancellationTrip } from './domain/trip-cancellation/Trip'
import Alert from './domain/gtfs-rt/entity/service-alert/Alert'
import { Alert } from './domain/gtfs-rt/entity/service-alert/Alert'
import { Entity } from './domain/gtfs-rt/entity/service-alert/Entity'
import Header from './domain/gtfs-rt/entity/Header'
import { Header } from './domain/gtfs-rt/entity/Header'
import { ActivePeriod } from './domain/gtfs-rt/entity/service-alert/ActivePeriod'
import { InformedEntity } from './domain/gtfs-rt/entity/service-alert/InformedEntity'
import { Entity as TripUpdateEntity } from './domain/gtfs-rt/entity/trip-update/Entity'
Expand Down
2 changes: 1 addition & 1 deletion src/domain/gtfs-rt/entity/Header.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export default class Header {
export class Header {
private readonly _gtfsRealtimeVersion: string
private readonly _incrementality: number
private readonly _timestamp: number
Expand Down
2 changes: 1 addition & 1 deletion src/domain/gtfs-rt/entity/Response.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Header from './Header'
import { Header } from './Header'
import { ResponseDTO } from '../../../Contracts'

export class Response<V> implements ResponseDTO {
Expand Down
2 changes: 1 addition & 1 deletion src/domain/gtfs-rt/entity/service-alert/Alert.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ActivePeriod } from './ActivePeriod'
import { InformedEntity } from './InformedEntity'

export default class Alert {
export class Alert {
private readonly _activePeriod: ActivePeriod[]
private readonly _effect: string
private readonly _cause: string
Expand Down

0 comments on commit 7a660fa

Please sign in to comment.