1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 package org.apache.directory.server.schema.bootstrap;
21
22
23 import javax.naming.NamingException;
24
25 import org.apache.directory.server.schema.bootstrap.AbstractBootstrapProducer;
26 import org.apache.directory.server.schema.bootstrap.ProducerCallback;
27 import org.apache.directory.server.schema.bootstrap.ProducerTypeEnum;
28 import org.apache.directory.server.schema.registries.Registries;
29 import org.apache.directory.server.schema.registries.SyntaxCheckerRegistry;
30
31
32
33
34
35
36
37
38
39 public class NisSyntaxProducer extends AbstractBootstrapProducer
40 {
41 public NisSyntaxProducer()
42 {
43 super( ProducerTypeEnum.SYNTAX_PRODUCER );
44 }
45
46
47
48
49
50
51
52
53
54 public void produce( Registries registries, ProducerCallback cb ) throws NamingException
55 {
56 BootstrapSyntax syntax;
57 SyntaxCheckerRegistry syntaxCheckerRegistry = registries.getSyntaxCheckerRegistry();
58
59
60 syntax = new BootstrapSyntax( "1.3.6.1.1.1.0.0", syntaxCheckerRegistry );
61 syntax.setDescription( "RFC2307 NIS Netgroup Triple" );
62 syntax.setNames( new String[]
63 { "NIS Netgroup Triple" } );
64 syntax.setHumanReadable( true );
65 cb.schemaObjectProduced( this, syntax.getOid(), syntax );
66
67
68 syntax = new BootstrapSyntax( "1.3.6.1.1.1.0.1", syntaxCheckerRegistry );
69 syntax.setNames( new String[]
70 { "NIS Boot Parameter" } );
71 syntax.setHumanReadable( true );
72 cb.schemaObjectProduced( this, syntax.getOid(), syntax );
73
74 }
75 }